cleaner URLS

  • Posts: 71
  • Thank you received: 1
3 years 4 months ago #327515

-- HikaShop version -- : 4.4.0

Hey,

How is it possible to remove hikashop-menu-for-categories-listing and component/hikashop from the URLs?


Best regards,

RG

Please Log in or Create an account to join the conversation.

  • Posts: 81481
  • Thank you received: 13062
  • MODERATOR
3 years 4 months ago #327520

Hi,

The text "hikashop-menu-for-categories-listing" is the alias of the menu item used by the current page.
It is added automatically by the Joomla SEF URL system.
Removing the alias of the current menu item is not possible unless that menu item is the homepage.
Changing that text can be done by simply changing the alias of the menu item in the Joomla menu manager.
The text "component/hikashop" is added by Joomla's SEF URL system automatically when no current menu item is used instead of the alias of the menu item (so that the routing system knows which component to call as it can't base itself on the settings of a menu item).
Removing it is not possible but it can be replaced by a menu item alias.

Now, how to change these depend on the situation.
I had a look at your website, and I can see for example that you have a products listing module on your homepage with links with "component/hikashop" in them.
This indicates that you didn't select any menu item in the "menu" setting under the "HikaShop options" tab of the module when editing it via the Joomla modules manager. You should select in there either a HikaShop products listing type menu item or a HikaShop categories listing type menu item. Then, "component/hikashop" will be replaced by the alias of that menu item.

The following user(s) said Thank You: RG

Please Log in or Create an account to join the conversation.

  • Posts: 71
  • Thank you received: 1
3 years 4 months ago #327586

Thank you Nicolas

The following user(s) said Thank You: Philip

Please Log in or Create an account to join the conversation.

  • Posts: 7
  • Thank you received: 0
1 year 9 months ago #343004

nicolas wrote: The text "hikashop-menu-for-categories-listing" is the alias of the menu item used by the current page.
It is added automatically by the Joomla SEF URL system.
Removing the alias of the current menu item is not possible unless that menu item is the homepage.
Changing that text can be done by simply changing the alias of the menu item in the Joomla menu manager.

Hi! Can I get more details? In which menu to change the alias?

Please Log in or Create an account to join the conversation.

  • Posts: 81481
  • Thank you received: 13062
  • MODERATOR
1 year 9 months ago #343028

Hi,

It's not in HikaShop but in Joomla. In the Menus->All menu items of Joomla's backend if you're on Joomla 4. There, search for the menu item you want to edit and change its alias to your needs.

Please Log in or Create an account to join the conversation.

  • Posts: 7
  • Thank you received: 0
1 year 9 months ago #343072

Hi! Thanks for the answer! But I don't understand the alias of which menu needs to be changed. For example: screenshot of the joomla menu item in the admin panel - prnt.sc/FbFuFQBSznpg , alias - ptitsevodstvo.
Screenshot on the website - prnt.sc/UAkTQJeCuOEu as seen in the address bar novakorm.esy.es/hikashop-menu-for-catego...isting/ptitsevodstvo . It is likely that the address with "hikashop-menu-for-categories-listing" is taken from the canonical link of the category Hikashop URL - /hikashop-menu-for-categories-listing/ptitsevodstvo . Screenshot - prnt.sc/x8z03_dU9f2d . Perhaps I created the canonical link incorrectly, so I don't understand which alias of which menu needs to be changed. I created the canonical link so that the URLs of the Mainmenu and offcanvas-menu items are identical.
I tried to change the aliases of many menu items, but nothing works.
I would be very grateful if you find it possible to help! I can give access to the admin panel of the site with Publisher rights. But most importantly, I need to figure out how to do it right! Perhaps it will be useful to other users as well. Thank you in advance!

Please Log in or Create an account to join the conversation.

  • Posts: 81481
  • Thank you received: 13062
  • MODERATOR
1 year 9 months ago #343073

Hi,

You have another menu item with the alias "hikashop-menu-for-categories-listing". So you need to edit that other menu item if you want to change its alias.
By default, that menu item with the alias "hikashop-menu-for-categories-listing" is in the "HikaShop default menus" menu.

Also, if you change the alias "hikashop-menu-for-categories-listing" to something else and you have canonical URLs with "hikashop-menu-for-categories-listing" in them, it means you'll also have to change the canonical URLs.

And if you want the elements to use your "ptitsevodstvo" menu item instead of "hikashop-menu-for-categories-listing" while you have the "force canonical URLs on listings" setting activated, changing the alias of the menu item won't help. Instead you want to change the canonical URLs to use "ptitsevodstvo" instead of "hikashop-menu-for-categories-listing".

The following user(s) said Thank You: bgl

Please Log in or Create an account to join the conversation.

Time to create page: 0.069 seconds
Powered by Kunena Forum