Yet another "No input file specified." thread

Nuno Magalhães nunomagalhaes at
Fri Sep 25 04:26:43 MSD 2009

On Fri, Sep 25, 2009 at 00:21, Rob Schultz <rschultz7 at> wrote:

>>        location ~ \.php$ {
>>                fastcgi_pass;
>>                fastcgi_index  index.php;
>>                include /etc/nginx/fastcgi_params;
>>        }

Try using something like:

	location ~ \.(php|html)$ {
		fastcgi_pass   localhost:yourPort;
		include fastcgi_params;
	# add aditional parameters only after the include, so they'll override
		fastcgi_index  index.php;
		fastcgi_param  SCRIPT_FILENAME /path/to/your/docroot$fastcgi_script_name;
		fastcgi_param DOCUMENT_ROOT /path/to/your/docroot;
		fastcgi_intercept_errors on; # for easier debug

Mainly, the document_root param should be afer the include, otherwise
you're using your server's doc_root instead of your site's doc_root. I


()  ascii-rubanda kampajno - kontraŭ html-a retpoŝto
/\  ascii ribbon campaign - against html e-mail

More information about the nginx mailing list