Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 09 Sep 2007 01:32:06 +0300
From:      OutBackDingo <outbackdingo@gmail.com>
To:        Peter Pluta <peter@placidpublishing.net>
Cc:        freebsd-questions@freebsd.org
Subject:   Nginx + FastCGI + PHP5 on FreeBSD 7.0
Message-ID:  <1189290726.8850.6.camel@dingo-laptop>
In-Reply-To: <12533660.post@talk.nabble.com>
References:  <12513880.post@talk.nabble.com> <fbpqui$vsh$1@sea.gmane.org> <12533660.post@talk.nabble.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Ok wizards.... 

Nginx Lighttpd Fast-cgi and PHP5

seems all configured, yet when i point a browser at a php page 
it tries to download the file, instead of render it in the browser,
any ideas what i missed

------nginx.conf--------------
#user  nobody;
worker_processes  1;

events {
    worker_connections  1024;
}

http {
    include       mime.types;
    default_type  application/octet-stream;

    sendfile        on;

    keepalive_timeout  65;

    server {
        listen       80;
        server_name  localhost;

        location / {
            root   /usr/local/www/nginx;
            index  index.html index.php index.htm;
        }

        error_page   500 502 503 504  /50x.html;
        location = /50x.html {
            root   /usr/local/www/nginx-dist;
        }

# .php5 sent to php5
    location ~ .*\.php5$ {
    include /usr/local/etc/nginx/fastcgi_params;
    fastcgi_pass  127.0.0.1:10005;
    fastcgi_index index.php;
    fastcgi_param SCRIPT_FILENAME /$fastcgi_script_name;
        }
}

and....
/usr/local/sbin/spawn-fcgi -f /usr/local/bin/php-cgi -a 127.0.0.1 -p 9000 -u www







Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1189290726.8850.6.camel>