PHP Not Working [2]
Ian Hobson
ian at ianhobson.co.uk
Mon Apr 18 02:27:09 MSD 2011
Hi Cain,
On 17/04/2011 20:46, Cain wrote:
> I am aware I am posting this again but a boy told me to change the port,
I haven't been called a boy these last 50 years! :)
> which I have however it only made loading the php page take longer, but
> it still ends in a resulted broken page.
>
snip
> # proxy the PHP scripts to Apache listening on 127.0.0.1:80
> #
> #location ~ \.php$ {
> #proxy_pass http://127.0.0.1;
> #}
>
> # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
> #
> location ~ \.php$ {
> fastcgi_pass thefoool.co.uk:81;
That is not port 9000 that is 81. Which are you using?
> fastcgi_index index.php;
I suspect the key parts you need are:
index index.php;
location ~ \.php {
fastcgi-pass 127.0.01:9000;
fastcgi-param SCRIPT_FILENAME
$document_root$fastcgi_script_name;
include /etc/nginx/fastcgi_params;
}
But you must match the port (the 9000) with the port you have started
php-fastcgi on.
Regards
Ian
More information about the nginx
mailing list