Sef urls problems, Hikashop add string to urls

  • Posts: 43
  • Thank you received: 1
8 years 3 months ago #247696

-- HikaShop version -- : 2.6.3
-- Joomla version -- : 3.6.2
-- PHP version -- : 5.6.19
-- Browser(s) name and version -- : firefox 47.0.1
-- Error-message(debug-mod must be tuned on) -- : #404 Page not found

In Hikashop are over 8200 products. Aliases of all products are set like product id's over phpmyadmin. So, product with id 1273441 must have alias: 1273441

But as result, all products urls are generated wrong and caused 404 error.

Why hikashop add this "p" to product alias??? The right product url must be: viva.superhosting.bg/~indugqog/produkti/p/1273441

You can see Sef urls configuration on attached screens. Hikashop version is latest - just downloaded from your website and updated.

Attachments:
Last edit: 8 years 3 months ago by eduarddimitrov. Reason: removed links

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 3 months ago #247697

Hi,

When the URL starts with a number, that number is the product ID.
If you are generating a SEF url and the alias is a number ; HikaShop must add an element so it won't mix-up between an alias and a product ID.
That is the reason why you have a "p".
If your alias is the product ID ; the best would be to remove the alias so the SEF url will start with the product ID.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
The following user(s) said Thank You: eduarddimitrov

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

  • Posts: 43
  • Thank you received: 1
8 years 3 months ago #247754

Jerome, thank you. To change alias for one product is not a problem, but products are over 8220. Is there any other way to remove this "p" from urls? May be to change some line in router?

Last edit: 8 years 3 months ago by eduarddimitrov.

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 3 months ago #247756

Hi,

Unfortunately, I cannot recommend that in any case.
If you modify the router in such way, you won't have any working routing if your product do not have any alias, if HikaShop have to generate a SEF URL with the product id and no alias ; that URL won't work. So it will be a serious bug.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

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

  • Posts: 43
  • Thank you received: 1
8 years 3 months ago #247861

Ok, we will change aliases in database again. What you recommend: just to add some symbol before numbers?

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

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
8 years 3 months ago #247891

Hi,

You can use a mass action to do such kind of repetitive task.
The idea is that the alias should not start with a digit ; otherwise HikaShop will add an "alpha" character before to not confuse the URL with a product id.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
The following user(s) said Thank You: eduarddimitrov

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

  • Posts: 43
  • Thank you received: 1
8 years 3 months ago #247918

Already done with sql query over phpmyadmin. Now all products are with "p-idofproduct". Thank you for support!

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

Time to create page: 0.042 seconds
Powered by Kunena Forum