on ‎2018 May 24 8:22 PM
I'm working with Hybris 6.2, I'm being asked to modify the way the URLs for the storefront product's details are handle.
The OOTB pattern that is handled is /{category-path}/{product-name}/p/{product-code} according to the information found on this link about SEO URLs(which contains error on the documentation), I have to modify the pattern that is used currently through customization.
The URL I'm being asked to set on the storefront should look like this /{category-path}/{product-name}/{product-code}, but I'm having doubts if Hybris is capable of handling URLs without delimiters like /p/ to difference between the category path, the product name and the product code.
Is it possible to handle these kind of URLs?
Request clarification before answering.
Hi ,
Please see this OOTB class : DefaultProductDataUrlResolver and based on the ulr mapping pattern
ProductPageController is calling.
You can override the UrlResolver to change the pattern and based on the you need to change request
mapping pattern in product page controller as well.
Thanks,
Venki
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
ya , that is the pattern is used request mapping on the controller. you can change it into name instead of /c/, you can write /categorycode/.
If you observe the url for category (xxx/c/xxx)and product(xxx/p/xxx), it contains /c/ and /p/ is using to identify the controller only so you can change as per your requirement.
Request mapping url pattern should be unique to identify the particular controller.
Thanks,
Venki
| User | Count |
|---|---|
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.