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

Popular posts from this blog

javascript - three.js lot of meshes optimization -

smartface.io - Proper way to change color scheme for whole application -

Email notification in google apps script -