CodeIgniter in localhost funktioniert gut, aber wenn ich es an den Server weitergegeben werden nur die index
Seite funktioniert.CodeIgniter arbeitet in localhost gut, aber wenn ich an den Server übergeben nur die Index-Seite arbeitet
Ich habe versucht, die config.php Wechsel durch Änderung:
$config['uri_protocol'] = 'PATH_INFO';
zu$config['uri_protocol'] = 'REQUEST_URI'
$config['index_page'] = 'index.php';
zu$config['index_page'] = 'index.php?';
Aber es ist immer noch nicht funktioniert.
config.php
Datei:
$config['base_url'] = 'http://s661658794.onlinehome.fr/admin';
$config['index_page'] = 'index.php';
$config['uri_protocol'] = 'REQUEST_URI';
.htaccess
Datei:
RewriteEngine on
RewriteCond $1 !^(index\.php|resources|robots\.txt)
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L,QSA]
## EXPIRES CACHING ##
<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType image/jpg "access 1 year"
ExpiresByType image/jpeg "access 1 year"
ExpiresByType image/gif "access 1 year"
ExpiresByType image/png "access 1 year"
ExpiresByType text/css "access 1 year"
</IfModule>
## EXPIRES CACHING ##
<ifModule mod_gzip.c>
mod_gzip_on Yes
mod_gzip_dechunk Yes
mod_gzip_item_include file .(html?|txt|css|js|php|pl)$
mod_gzip_item_include handler ^cgi-script$
mod_gzip_item_include mime ^text/.*
mod_gzip_item_include mime ^application/x-javascript.*
mod_gzip_item_exclude mime ^image/.*
mod_gzip_item_exclude rspheader ^Content-Encoding:.*gzip.*
</ifModule>
<ifModule mod_headers.c>
Header set Connection keep-alive
</ifModule>
RewriteEngine on
RewriteCond %{HTTP_HOST} ^www\.(.*)$ [NC]
RewriteRule ^(.*)$ http://%1%{REQUEST_URI} [R=301,QSA,NC,L]
`
Beim Verlegen des anderen Seite geht: Fehler 404 - Nicht gefunden – fegugi
Verwenden Sie Apache oder Nginx auf Ihrer Produktionsmaschine? Und/oder haben Sie installiert, welche Variante der URL Neuschreibung notwendig ist? – castis
Der Server verwendet Apache, denke ich. – fegugi