Hello,
i have a question for developers ...
for categories and products , instead of having the product name or category name appears in the URL Rewrite , i would like the SKU to appear instead of product name , and Description instead of the category name .
Any idea how can i do that ?
Regards,
Developers : Using anohter filed for SEO ?
-
- Lieutenant, Jr. Grade (LT JG)
- Posts: 28
- Joined: Wed Jun 04, 2008 1:45 am
-
- Lieutenant, Jr. Grade (LT JG)
- Posts: 28
- Joined: Wed Jun 04, 2008 1:45 am
Re: Developers : Using anohter filed for SEO ?
any help would be appreciated ... basically where can i find in the code what tells the url re-write to use product name and alter it with SKU for example
thanks
thanks
-
- Lieutenant, Jr. Grade (LT JG)
- Posts: 28
- Joined: Wed Jun 04, 2008 1:45 am
Re: Developers : Using anohter filed for SEO ?
i hope someone answers this question
this is very important , because if you have non-english name for your product/catrgory , it wouldn't appear right in the url name
this is very important , because if you have non-english name for your product/catrgory , it wouldn't appear right in the url name
Re: Developers : Using anohter filed for SEO ?
URLs are generated using UrlGenerator class.
UrlGenerator.GetBrowseUrl is called in various places in ASPX files. You need to update these calls and pass SKU instead of Product name as parameter.
For example you can replace this
with this
UrlGenerator.GetBrowseUrl is called in various places in ASPX files. You need to update these calls and pass SKU instead of Product name as parameter.
For example you can replace this
Code: Select all
string url = UrlGenerator.GetBrowseUrl(product.ProductId, CatalogNodeType.Product, product.Name);
Code: Select all
string url = UrlGenerator.GetBrowseUrl(product.ProductId, CatalogNodeType.Product, product.Sku);