# RewriteEngine on
# RewriteCond %{HTTPS} off
# RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [L,R]

# LANDING PAGE
RewriteRule ^landing-page$ /landing-page.php [L]

# AUTH | BẢN QUYỀN LXTDEV
RewriteRule ^auth/login$ /pages/auth/login.php [L]
RewriteRule ^auth/register$ /pages/auth/dangky.php [L]
RewriteRule ^auth/password-reset$ /pages/auth/quenpass.php [L]
RewriteRule ^resetpass$ /pages/auth/datlaipass.php [L]
RewriteRule ^auth/logout$ /pages/auth/logout.php [L]
#MÃ NGUỒN 
RewriteRule ^ma-nguon$ /pages/manguon/manguon.php [L]
RewriteRule ^ma-nguon/([A-Za-z0-9-]+) /pages/manguon/viewcode.php?id=$1 [L]
RewriteRule ^history-ma-nguon$ /pages/manguon/lichsumuacode.php [L]
#ACCOUNT 
RewriteRule ^profile$ /pages/profile.php [L]
RewriteRule ^password$ /pages/changepass.php [L]
RewriteRule ^cap-bac$ /pages/rank.php [L]
#NẠP TIỀN
RewriteRule ^nap-tien$ /pages/naptien/index.php [L]
RewriteRule ^nap-the$ /pages/naptien/napthe.php [L]
RewriteRule ^nap-bank$ /pages/naptien/napatm.php [L]
#CHỨC NĂNG

RewriteRule ^tao-subdomain$ /pages/subdomain/index.php [L]
RewriteRule ^quanly-subdomain/([A-Za-z0-9-]+) /pages/subdomain/quanlysubdomain.php?id=$1 [L]
RewriteRule ^add-record/([A-Za-z0-9-]+) /pages/subdomain/add-record.php?id=$1 [L]
RewriteRule ^server-hosting$ /pages/hosting/index.php [L]
RewriteRule ^server-hosting/([A-Za-z0-9-]+) /pages/hosting/cuahang.php?server=$1 [L]
RewriteRule ^thanh-toan-host/([A-Za-z0-9-]+) /pages/hosting/thanhtoan.php?id=$1 [L]
RewriteRule ^history-hosting$ /pages/hosting/lshost.php [L]
RewriteRule ^quan-ly-host/([A-Za-z0-9-]+) /pages/hosting/quanlyhost.php?id=$1 [L]
RewriteRule ^reg-mien$ /pages/domain/mien.php [L]
RewriteRule ^history-mien$ /pages/domain/lsmuamien.php [L]
RewriteRule ^tao-web$ /pages/taoweb/index.php [L]
RewriteRule ^history-tao-web$ /pages/taoweb/lstaoweb.php [L]
RewriteRule ^history-reg-web/([A-Za-z0-9-]+) /pages/taoweb/viewtaoweb.php?id=$1 [L]
RewriteRule ^tao-web/([A-Za-z0-9-]+) /pages/taoweb/taoweb.php?id=$1 [L]
RewriteRule ^tao-logo$ /pages/logo/logo.php [L]
RewriteRule ^tao-logo/([A-Za-z0-9-]+) /pages/logo/viewlogo.php?id=$1 [L]
RewriteRule ^history-logo$ /pages/logo/lslogo.php [L]
RewriteRule ^cron-jobs$ /pages/cronjobs/index.php [L]
RewriteRule ^history-subdomain$ /pages/subdomain/ls-subdomain.php [L]
RewriteRule ^edit-record/([A-Za-z0-9-]+) /pages/subdomain/edit-record.php?id=$1 [L]
RewriteRule ^check-mien$ /pages/check/ktmien.php [L]

#AJAX

RewriteRule ^ajax/auth/xulylogin$ /ajax/auth/xulylogin.php [L]
RewriteRule ^ajax/auth/xulyregister$ /ajax/auth/xulyregister.php [L]
RewriteRule ^ajax/auth/reset-pass$ /ajax/auth/reset-pass.php [L]
RewriteRule ^ajax/auth/xu-ly-mat-khau$ /ajax/auth/dat-lai-pass.php [L]
RewriteRule ^ajax/hosting/xulyhost$ /ajax/hosting/xulyhost.php [L]
RewriteRule ^ajax/hosting/changepass$ /ajax/hosting/changepass.php [L]
RewriteRule ^ajax/hosting/resethost$ /ajax/hosting/resethost.php [L]
RewriteRule ^ajax/hosting/xoahost$ /ajax/hosting/xoahost.php [L]
RewriteRule ^ajax/hosting/changedomain$ /ajax/hosting/changedomain.php [L]
RewriteRule ^ajax/hosting/giahan$ /ajax/hosting/giahan.php [L]
RewriteRule ^ajax/manguon/xulymuacode$ /ajax/manguon/xulymuacode.php [L]
RewriteRule ^ajax/taoweb/xulytaoweb$ /ajax/taoweb/xulytaoweb.php [L]
RewriteRule ^ajax/cronjob/mincron$ /ajax/cronjob/mincron.php [L]
RewriteRule ^ajax/cronjob/cronjob$ /ajax/cronjob/cronjob.php [L]
RewriteRule ^ajax/cronjob/edit-cron$ /ajax/cronjob/edit-cron.php [L]
RewriteRule ^ajax/cronjob/status_cron$ /ajax/cronjob/status_cron.php [L]



#NẠP TIỀN
RewriteRule ^ajax/naptien/napthe$ /ajax/naptien/napthe.php [L]
#404
ErrorDocument 404 /404.php
ErrorDocument 503 /503.php
ErrorDocument 403 /403.php
ErrorDocument 502 /502.php
ErrorDocument 521 /521.php
<Files 403.shtml>
order allow,deny
allow from all
</Files>

RewriteEngine On
RewriteRule ^tin-tuc/([0-9]+)$ view-news.php?id=$1 [L]
