# Redirect non-www to www

# Create pretty URLs
# End: Create pretty URLs

# Specific redirections
if ($args ~* ^r_code=56233D5$){ rewrite ^/$ /r_code-56233D5.html? permanent; }
if ($args ~* ^code=dGtTLj0y$){ rewrite ^/get-envelop\.php$ /get-envelop_code-dGtTLj0y.html? permanent; }
if ($args ~* ^r_code=G4G9Q46$){ rewrite ^/register$ /register_r_code-G4G9Q46.html? permanent; }

# Redirect all extensions to html
if ($is_args = ''){
	rewrite ^([^.]*)\.shtml$ $1.html permanent;
	rewrite ^([^.]*)\.phtml$ $1.html permanent;
	rewrite ^([^.]*)\.jhtml$ $1.html permanent;
	rewrite ^([^.]*)\.htm$ $1.html permanent;
	rewrite ^([^.]*)\.php$ $1.html permanent;
	rewrite ^([^.]*)\.aspx$ $1.html permanent;
	rewrite ^([^.]*)\.asp$ $1.html permanent;
	rewrite ^([^.]*)\.jsp$ $1.html permanent;
	rewrite ^([^.]*)\.apk$ $1.html permanent;
}
# End: Redirect all extensions to html
