Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nginx #1

Closed
nervo opened this issue Feb 19, 2013 · 4 comments
Closed

Nginx #1

nervo opened this issue Feb 19, 2013 · 4 comments

Comments

@nervo
Copy link
Contributor

nervo commented Feb 19, 2013

Dude, how do you handle url rewriting in your framework ?

I guess you are using apache, what is your vhost configuration ?
I can not reproduce it in nginx...

@sasanrose
Copy link
Owner

Really sorry for the delay. My nginx configuration is:

server {

    listen   80; ## listen for ipv4
    listen   [::]:80 default ipv6only=on; ## listen for ipv6

    server_name  localhost;

    access_log  /var/log/nginx/localhost.access.log;
        root /var/www/phpredmin/public/;
    index index.php index.html index.htm;

        location ~ \.php$ {
                fastcgi_split_path_info ^(.+\.php)(/.+)$;
                # NOTE: You should have "cgi.fix_pathinfo = 0;" in php.ini

            fastcgi_pass unix:/tmp/php.socket;
                fastcgi_index index.php;
                fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
                include fastcgi_params;

        }
        location @rewrite {
                # Some modules enforce no slash (/) at the end of the URL
                # Else this rewrite block wouldn't be needed (GlobalRedirect)
                rewrite ^/(.*)$ /index.php?q=$1;
        }

        location ~ ^/.*{
                try_files $uri @rewrite;
        }
}

@nervo
Copy link
Contributor Author

nervo commented Mar 23, 2013

Yeah, a lot better :)

White page on "info" tab, any chances to be a routing problem ?

@sasanrose
Copy link
Owner

Mm, I don't think so, have you checked logs in log directory? There should be more details regarding this.

@devoto13
Copy link

Thank you for this. I think this information should be included or linked from here https://github.com/sasanrose/phpredmin#installation. It will save a lot of time for people, who are using Nginx as their server.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants