Welcome! Log In Create A New Profile

Advanced

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

Francis Daly
July 06, 2015 02:22PM
On Mon, Jul 06, 2015 at 12:40:37PM -0400, ramsoft75 wrote:

Hi there,

Things seem to be getting a lot more complicated than they need to.

> The "^/$" came from :
>
> #to detect if the device with www entered in domain is mobile
> if ($http_user_agent ~* '(iPhone|iPod|iPad|Android|BlackBerry|webOS|Windows
> Phone)') {
> rewrite ^/$ http://m.domain.com$request_uri;
> }

That's not the configuration you started with.

You indicated that with your starting configuration, some requests did
get the response that you wanted, and some did not.

I have been unable to reproduce the "did not" case; probably because I
do not fully understand what your expectations are.

Can you go back to your starting configuration, and do whatever it takes
to get the "ok" request/response, and then show the access_log entry
for that request?

(Or just find the old log file.)

The log line should show a GET going to the "www" server, with a response
code of 302. Ideally, it will also show the user-agent involved.

Then can you show the log line corresponding to a "not ok"
request/response? It should also show a GET going to the "www" server,
with a response code of 302, if I have understood correctly what you
have reported.

Comparing the two log lines, particularly the request and the user-agent,
may show why the "not ok" one responded as it did.

f
--
Francis Daly francis@daoine.org

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

Nginx doesn't redirect www no m in Safari, iPhone, iPad

ramsoft75 July 03, 2015 07:04AM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

Francis Daly July 03, 2015 01:48PM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

ramsoft75 July 04, 2015 02:03PM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

ramsoft75 July 04, 2015 02:20PM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

Francis Daly July 04, 2015 02:36PM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

ramsoft75 July 05, 2015 03:31PM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

ramsoft75 July 06, 2015 04:52AM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

Francis Daly July 06, 2015 08:24AM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

ramsoft75 July 06, 2015 10:10AM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

ramsoft75 July 06, 2015 10:11AM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

ramsoft75 July 06, 2015 12:39PM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

ramsoft75 July 06, 2015 12:40PM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

ramsoft75 July 06, 2015 12:57PM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

Alt July 06, 2015 02:33PM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

Francis Daly July 06, 2015 02:22PM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

oscaretu . July 07, 2015 03:22AM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

ramsoft75 July 07, 2015 05:28AM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

Alt July 07, 2015 06:29AM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

ramsoft75 July 07, 2015 10:44AM

Re: Nginx doesn't redirect www no m in Safari, iPhone, iPad

oscaretu . July 07, 2015 08:34AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 114
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready