Pomoc - Szukaj - Użytkownicy - Kalendarz
Pełna wersja: .htaccess / rewrite i błąd
Forum PHP.pl > Forum > Serwery WWW
gothye
witam
na localhost mi działa wiec uznałem ze jest ok , lecz po wzuceniu na serwer dostaję :

  1. Internal Server Error
  2.  
  3. The server encountered an internal error or misconfiguration and was unable to complete your request.
  4.  
  5. Please contact the server administrator, [no address given] and inform them of the time the error occurred, and anything you might have done that may have caused the error.
  6.  
  7. More information about this error may be available in the server error log.


mój .htaccess :
  1. Options -MultiViews
  2. RewriteEngine On
  3.  
  4. #RewriteBase /
  5.  
  6. RewriteCond %{REQUEST_FILENAME} !-f
  7. RewriteCond %{REQUEST_FILENAME} !-d
  8. RewriteRule . index.php [L]


gdzie doszukiwać się problemu ?
erix
Tak się robi na niektórych serwerach, jeśli modyfikujesz Options.

Ale równie prawdopodobne jest również to, że na serwerze nie ma mod_rewrite. winksmiley.jpg
gothye
usunołem options i to samo , rewrite jest napewno na serwerze właczone
gigzorr
Cytat(gothye @ 10.06.2010, 09:03:59 ) *
witam
na localhost mi działa wiec uznałem ze jest ok , lecz po wzuceniu na serwer dostaję :

  1. Internal Server Error
  2.  
  3. The server encountered an internal error or misconfiguration and was unable to complete your request.
  4.  
  5. Please contact the server administrator, [no address given] and inform them of the time the error occurred, and anything you might have done that may have caused the error.
  6.  
  7. More information about this error may be available in the server error log.


mój .htaccess :
  1. Options -MultiViews
  2. RewriteEngine On
  3.  
  4. #RewriteBase /
  5.  
  6. RewriteCond %{REQUEST_FILENAME} !-f
  7. RewriteCond %{REQUEST_FILENAME} !-d
  8. RewriteRule . index.php [L]


gdzie doszukiwać się problemu ?

spróboj taK:
Kod
Options FollowSymLinks
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . index.php [L][/html]
gothye
gigzorr to samo kod http:// 500 sad.gif( ,od czego moze byc to jeszcze uzależnione ?

dodam że wczesniej na stronie był .htaccess w formie :

  1. RewriteEngine on
  2. RewriteRule ^panel$ /panel/index.php [R=301,L]
  3. RewriteRule ^panel/index.html$ /panel/index.php [R=301,L]
  4. RewriteRule ^sitemap.xml$ /sitemap.php [L]
  5. RewriteRule ^(lib.*|test.*|pic.*|_.*|.*\.php.*|adm.*|Skin.*|oldadm.*|oldlib.*|panel.*)$ $1 [L]
  6. RewriteRule ^(alr.*) <a href="http://strona.pl" target="_blank">http://strona.pl</a>[R=301,L]
  7. RewriteRule ^(.*) /index.php?url=$1 [L]


strona ulega teraz zmiane w pewnych fragmentach :/ ,powyższy htaccess działa dla starego skryptu ,lecz chce napisać od nowa ,strone
erix
Samo RewriteEngine On też wywala?
gothye
Samo RewriteEngine On też wywala?

nie ,jest w pożądku ,serwer nie pokazuje żadnego błedu
vokiel
Zapisujesz logi mod_rewrite?
gothye
do logów nie mam dostępu na tym hostingu :/
To jest wersja lo-fi głównej zawartości. Aby zobaczyć pełną wersję z większą zawartością, obrazkami i formatowaniem proszę kliknij tutaj.
Invision Power Board © 2001-2025 Invision Power Services, Inc.