Welcome! Log In Create A New Profile

Advanced

Re: Problem with fastcgi_split_path_info on ubuntu precise

Francis Daly
May 14, 2013 05:40PM
On Tue, May 14, 2013 at 10:17:13AM -0400, vilsack wrote:
> Francis Daly Wrote:
> > On Sun, May 05, 2013 at 07:04:21AM -0400, zakaria wrote:

Hi there,

> > > location ~ [^/]\.php(/|$) {
> >
> > Just as another alternative, it is probably possible to use named captures
> > in the "location" regex and avoid using fastcgi_split_path_info at all
> > -- with everything up to and including ".php" being used as the script
> > name, and something like "(/.*)?$" being the path info.

> Francis, could you please show me an example?

location ~ ^(?<script_name>.+\.php)(?<path_info>/.*)?$ {

is one possible way.

Then use $script_name and $path_info as you see fit.

> I'm encountering this issue on Ubuntu 12.04.2 LTS while trying to set up
> Phalcon; a c lib/framework for PHP. So far the other fixes in this thread
> haven't worked.

"this issue" is "everything works fine, until you use try_files in
the same location as fastcgi_split_path_info", unless I misunderstand
things. It should be easy enough to test -- just comment out the try_files
and see that your request gives the expected response.

> Phalcon's Doc: http://docs.phalconphp.com/en/latest/reference/nginx.html
>
> I think Phalcon is dependent on how fastcgi_split_info works, so I'm trying
> to "replicate" how it handles the rewrite using regex. Am I going about
> this the wrong way?

That Phalcon doc seems to suggest four distinct and different ways
of configuring nginx, so that it works with four different ways of
configuring Phalcon.

None of them seem to use try_files in the same (useful) location as
fastcgi_split_path_info.

What is the one way that you have configured Phalcon?

What is the matching one way that you have configured nginx?

What request do you make, what response do you get, and what response
do you expect?

If your testing suggests that this is a different issue, it's probably
worth creating a new thread for further responses.

Cheers,

f
--
Francis Daly francis@daoine.org

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Problem with fastcgi_split_path_info on ubuntu precise

zakaria May 03, 2013 09:44PM

Re: Problem with fastcgi_split_path_info on ubuntu precise

GreenGecko May 03, 2013 09:56PM

Re: Problem with fastcgi_split_path_info on ubuntu precise

zakaria May 03, 2013 11:23PM

Re: Problem with fastcgi_split_path_info on ubuntu precise

Francis Daly May 04, 2013 07:58AM

Re: Problem with fastcgi_split_path_info on ubuntu precise

zakaria May 04, 2013 07:41PM

Re: Problem with fastcgi_split_path_info on ubuntu precise

B.R. May 04, 2013 08:16PM

Re: Problem with fastcgi_split_path_info on ubuntu precise

zakaria May 04, 2013 09:02PM

Re: Problem with fastcgi_split_path_info on ubuntu precise

Francis Daly May 05, 2013 04:00AM

Re: Problem with fastcgi_split_path_info on ubuntu precise

zakaria May 05, 2013 07:04AM

Re: Problem with fastcgi_split_path_info on ubuntu precise

Francis Daly May 07, 2013 04:38PM

Re: Problem with fastcgi_split_path_info on ubuntu precise

vilsack May 13, 2013 02:49PM

Re: Problem with fastcgi_split_path_info on ubuntu precise

Francis Daly May 14, 2013 05:40PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 306
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready