Quantcast
Channel: Nginx Forum - Nginx Mailing List - English
Viewing all articles
Browse latest Browse all 7229

Help with specific redirect to https (8 replies)

$
0
0
I'm trying to redirect anyURL that contains "UserLogin" (ie: Mediawiki) to
https. This is what I've tried:

rewrite .*UserLogin.* https://domain.com$request_uri? permanent;
----
rewrite UserLogin https://domain.com$request_uri? permanent;
----
rewrite ^.*UserLogin.*$ https://domain.com$request_uri? permanent;
----
location ~* .*UserLogin.* {
return 301 https://domain.com$request_uri;
}
----
location ~ .*UserLogin.* {
return 301 https://domain.com$request_uri;
}

All of them have no effect. I'm running out of trial to match my error.
Can anyone tell me what I'm doing wrong? Thank you.

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

Viewing all articles
Browse latest Browse all 7229

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>