NickTaporuk/cloth/master/simpla/rest/.htaccess - Htaccess File

NickTaporuk/cloth/master/simpla/rest/.htaccess

<Limit GET POST PUT DELETE>
Allow from all
</Limit>

AddDefaultCharset UTF-8

RewriteEngine on

# Товары
RewriteRule  ^products/?$                          index.php?resource=products                                          [L,QSA]
RewriteRule  ^products/([d,]+)/?$                 index.php?resource=products&id=$1                                    [L,QSA]
RewriteRule  ^categories/(d+)/products/?$         index.php?resource=products&category=$1                           [L,QSA]
RewriteRule  ^categories/(d+)/brands/(d+)/products/?$         index.php?resource=products&category=$1&category=$2                          [L,QSA]

RewriteRule  ^categories/?$                        index.php?resource=categories                                        [L,QSA]

RewriteRule  ^products/(d+)/categories/?$         index.php?resource=products_categories&product_id=$1                 [L,QSA]

RewriteRule  ^orders/(d+)/purchases/?$           index.php?resource=purchases&order_id=$1                            [L,QSA]

# Blog
RewriteRule  ^blog/?$                          index.php?resource=blog                                         [L,QSA]
RewriteRule  ^blog/([d,]+)/?$                 index.php?resource=blog&id=$1                                    [L,QSA]

# Orders
RewriteRule  ^orders/?$                          index.php?resource=orders                                          [L,QSA]
RewriteRule  ^orders/([d,]+)/?$                 index.php?resource=orders&id=$1                                    [L,QSA]

On Github License

Files

Download PDF of Htaccess file
GET, POST, PUT

Comments

Apache