丁度。質問を言い換えて、わざわざこのサイトを検索する必要があります。
OpenCart Admin -> Catalog -> Categories -> Name -> Data Tab -> SEO Keyword:
ブランド・カテゴリー(例)オアシス・シューズ
OpenCart Admin -> Catalog -> Products -> Name -> Data Tab -> SEO Keyword:
??-商品名(商品ID)
56-レッド-トレーナー
Nginx: (Apache の .htaccess も同様です。Apache の .htaccess でも、これは Opencart SEO Urls を有効にした後に既に標準になっています。nginx では手作業が必要です)
server {
listen 80;
server_name site.com www.site.com;
root /var/www/www.site.com/web;
index index.php index.html index.htm;
location /admin {
index index.php;
}
location / {
try_files $uri @opencart;
# cat
rewrite ^/oasis/shoes?$ /index.php?route=product/category&path=1 last;
# product
rewrite ^/oasis/shoes/(.*)$ /index.php?route=product/product&path=2&product_id=$1 last;
}
location @opencart {
rewrite ^/(.+)$ /index.php?route=$1 last;
}
location = /favicon.ico {
log_not_found off;
access_log off;
}
location = /robots.txt {
allow all;
log_not_found off;
access_log off;
}
location ~* \.(engine|inc|info|ini|install|make|module|profile|test|po|sh|.*sql|theme|tpl(\.php)?|xtmpl)$|^(\..*|Entries.*|Repository|Root|Tag|Template)$|\.php_ {
deny all;
}
location ~ /\. {
deny all;
access_log off;
log_not_found off;
}
location ~* \.(jpg|jpeg|png|gif|css|js|ico)$ {
expires max;
log_not_found off;
}
location ~ \.php$ {
include /etc/nginx/fastcgi_params;
fastcgi_pass 127.0.0.1:9000;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
}
URL を作成します
site.com/oasis/shoes
site.com/oasis/shoes/56-red-trainers