0

I deployed a symfony2 application on godaddy and I got this error: no input file specified. After some research I managed to solve with some changes on .htaccess file:

DirectoryIndex app.php
    <IfModule mod_rewrite.c>
        RewriteEngine On
        RewriteBase /
        RewriteCond %{REQUEST_FILENAME} !-f
        RewriteRule ^(.*)$ /app.php/ [QSA,L]
    </IfModule>

this works but only for urls like /mycontroller, I still get errors when using urls like /mycontroller/newaction. what else can I change to manage it working? thanks

user3174311
  • 1,714
  • 5
  • 28
  • 66

1 Answers1

2

Here is a good post how to fix that problem.

When getting started with Symfony2 using Apache and fast-cgi for PHP, you may get the following message come up when trying to open up the /app_dev.php/demo URL.

No input file specified. This occurs because the url rewrite module isn’t passing along the pathinfo details properly to the fcgi php. Here’s how you can fix it.

1.) Open the relavent php.ini file
2.) Look for the cgi.fix_pathinfo setting.
3.) You’ll most likely find it set to 0.
4.) Change it so that it reads cgi.fix_pathinfo=1
5.) Save the changes. Restart Apache.
6.) Try loading up /app_dev.php/demo/. It should work now.

http://wilt.isaac.su/articles/symfony2-no-input-file-specified-

René Höhle
  • 26,716
  • 22
  • 73
  • 82