Rewrite nginx url specific location url with PHP -
i'm trying rewrite location https.
however want @ specific location: http://test.org/forums/dfjk34dkk25cm369aa135cs56v34/
i want php files in directory redirected https.
my current attempt hasn't worked out. have done wrong?
location ~ /forums/dfjk34dkk25cm369aa135cs56v34\.php(/|$) { return 301 https://$host$request_uri; }
this did trick.
location ~ ^/forums/dfjk34dkk25cm369aa135cs56v34/.*php(/|$) { return 301 https://$host$request_uri; }
Comments
Post a Comment