Reputation: 11031
I have several applications running on Kohana 2.3.x. Today my hosting provider u pgraded the machines and my sites stopped running. I get the No input file specified
when trying to open website. I figures out there is something wrong with .htaccess
file especially the rule where I oust index.php part... I need urget fi for this! Thank you. My .htaccess:
# Turn on URL rewriting
RewriteEngine On
# Put your installation directory here:
# If your URL is www.example.com/kohana/, use /kohana/
# If your URL is www.example.com/, use /
RewriteBase /
# Protect application and system files from being viewed
RewriteCond $1 ^(system)
# Rewrite to index.php/access_denied/URL
RewriteRule ^(.*)$ index.php/access_denied/$1 [PT,L]
# Allow these directories and files to be displayed directly:
# - index.php (DO NOT FORGET THIS!)
# - robots.txt
# - favicon.ico
# - Any file inside of the images/, js/, or css/ directories
RewriteCond $1 ^(index\.php|robots\.txt|sitemap\.xml|favicon\.ico|static/images|static/js|static/css|static/tutorials|upload)
# No rewriting
RewriteRule ^(.*)$ - [PT,L]
# Rewrite all other URLs to index.php/URL
RewriteRule ^(.*)$ index.php/$1 [PT,L]
#AddHandler application/x-httpd-php5 .php
If I comment this part RewriteRule ^(.*)$ index.php/$1 [PT,L]
then site opens. What is wrong?
Upvotes: 0
Views: 2992
Reputation: 51
Probably you are using a host with PHP installed in CGI mode.
You can try this:
RewriteRule ^(.+)$ index.php?$0 [PT,L,QSA]
or this:
RewriteRule ^(.+)$ index.php?kohana_uri=$1 [L]
Regards
Upvotes: 1