Proper way to convert an apache rewrite rule

ST smntov at
Sun Jun 4 19:56:11 UTC 2017


I'm new to nginx and try to move an old website from apache to nginx.
While getting rid of the .htaccess file I've encountered following
rewrite rule:

RewriteCond %{QUERY_STRING} id=([^&]*) [NC,OR]
RewriteCond %{QUERY_STRING} daily=([^&]*) [NC]
RewriteCond %{REQUEST_URI} !mobSpecCycle [NC]
RewriteCond %{REQUEST_URI} !mobSpecTheme [NC]
RewriteRule ^rss\/mobSpec([^\/]+)/?$ /rss/mobSpec$1/mobSpec$1_%1.html

Could you, please, help me to convert it to nginx "the right way"?

Thank you in advance!

More information about the nginx mailing list