# Create pretty URLs
# End: Create pretty URLs

# Specific redirections
if ($args ~* ^car_type=경차$){ rewrite ^/rent/list\.php$ /rent/list_car_type-경차.html? permanent; }
if ($args ~* ^car_type=소형/준중형$){ rewrite ^/rent/list\.php$ /rent/list_car_type-소형_준중형.html? permanent; }
if ($args ~* ^car_type=중형차$){ rewrite ^/rent/list\.php$ /rent/list_car_type-중형차.html? permanent; }
if ($args ~* ^car_type=고급차$){ rewrite ^/rent/list\.php$ /rent/list_car_type-고급차.html? permanent; }
if ($args ~* ^car_type=RV/승합차$){ rewrite ^/rent/list\.php$ /rent/list_car_type-RV_승합차.html? permanent; }
if ($args ~* ^car_type=수입차$){ rewrite ^/rent/list\.php$ /rent/list_car_type-수입차.html? permanent; }
if ($args ~* ^car_type=전기차$){ rewrite ^/rent/list\.php$ /rent/list_car_type-전기차.html? permanent; }
if ($args ~* ^site_code=$){ rewrite ^/company/info\.php$ /company/info_site_code.html? permanent; }
if ($args ~* ^site_code=$){ rewrite ^/company/rule_01\.php$ /company/rule_01_site_code.html? permanent; }
if ($args ~* ^site_code=$){ rewrite ^/company/rule_02\.php$ /company/rule_02_site_code.html? permanent; }
if ($args ~* ^site_code=$){ rewrite ^/company/rule_03\.php$ /company/rule_03_site_code.html? permanent; }
if ($args ~* ^c=insert$){ rewrite ^/member/join\.html$ /member/join_html/c-insert.html? permanent; }
if ($args ~* ^cmid=$){ rewrite ^/member/id_check\.php$ /member/id_check_cmid.html? permanent; }
if ($args ~* ^mid=$){ rewrite ^/member/id_check\.php$ /member/id_check_mid.html? permanent; }
if ($args ~* ^cm_pwd=$){ rewrite ^/member/pw_check1\.php$ /member/pw_check1_cm_pwd.html? permanent; }
if ($args ~* ^m_pwd=$){ rewrite ^/member/pw_check1\.php$ /member/pw_check1_m_pwd.html? permanent; }
if ($args ~* ^cm_pwd=$){ rewrite ^/member/pw_check\.php$ /member/pw_check_cm_pwd.html? permanent; }
if ($args ~* ^m_pwd=$){ rewrite ^/member/pw_check\.php$ /member/pw_check_m_pwd.html? permanent; }
if ($args ~* ^site_code=$){ rewrite ^/res/res_chk\.php$ /res/res_chk_site_code.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
