Re: Need to remove folder name from URL

2015-02-12 Thread Francis Daly
On Thu, Feb 12, 2015 at 03:06:26AM -0500, strtwtsn wrote: Hi there, > We need the pages below folder_name to be accessible at > example1.com/folder_name/page1 example1.com/folder_name/page2 etc location /folder_name/ { proxy_pass http://example.com; } So when the user makes a request of nginx

Re: Need to remove folder name from URL

2015-02-12 Thread strtwtsn
We've got a website that is available at example.com. A subsection of the page is available at example.com/folder_name/page1 example.com/folder_name/page2 etc We need the pages below folder_name to be accessible at example1.com/folder_name/page1 example1.com/folder_name/page2 etc This is worki

Re: Need to remove folder name from URL

2015-02-11 Thread Francis Daly
On Wed, Feb 11, 2015 at 11:35:03AM -0500, strtwtsn wrote: Hi there, > Clicking the links on the page take me to the correct page on example.com, > but show example1.com in the addressbar. > > eg > > example1.com//history > > I need to hide the part of it. It sounds like you want a request

Re: Need to remove folder name from URL

2015-02-11 Thread strtwtsn
Will do...in case this helps...here's my config server { listen 80; client_max_body_size 4G; server_name example1.com; passenger_enabled on; root /home//current/public; rails_env production; keepalive_timeout 5; location = / { proxy_pass http://example1.com/; // This is to silently redirect th

Re: Need to remove folder name from URL

2015-02-11 Thread itpp2012
Enable debug and see the logs whats actually being rewritten. Posted at Nginx Forum: http://forum.nginx.org/read.php?2,256577,256580#msg-256580 ___ nginx mailing list nginx@nginx.org http://mailman.nginx.org/mailman/listinfo/nginx

Re: Need to remove folder name from URL

2015-02-11 Thread strtwtsn
Thanks, trying that gives me www.example1.com//history but the pages doesnt display Posted at Nginx Forum: http://forum.nginx.org/read.php?2,256577,256579#msg-256579 ___ nginx mailing list nginx@nginx.org http://mailman.nginx.org/mailman/listinfo/n

Re: Need to remove folder name from URL

2015-02-11 Thread itpp2012
Maybe something like; rewrite//([^/]+) /$1 break; Posted at Nginx Forum: http://forum.nginx.org/read.php?2,256577,256578#msg-256578 ___ nginx mailing list nginx@nginx.org http://mailman.nginx.org/mailman/listinfo/nginx

Need to remove folder name from URL

2015-02-11 Thread strtwtsn
Hi We're using proxy_pass to silently forward a website to a different URL. Here is the code location ^~/ { proxy_pass http://www.example.org/; } So let's say the site is example1.org. Going to www.example1.com//history correctly shows that page that would be visibile at www.example.org//his