Checkout Product listing menu links?

  • Posts: 18
  • Thank you received: 0
10 years 4 months ago #188949

-- url of the page with the problem -- : www.spinboom.com
-- HikaShop version -- : 2.3.2
-- Joomla version -- : 3.3.1
-- PHP version -- : 5.4.34

Hey,

We are using 2 distinct categories in our online store, Music and Sounds.

Although it was pretty easy to setup the product and category listing menus for the 2 website areas (sound product listings are displayed in the Sound menu pages while Music product listings in the Music menu pages) when it comes to the checkout which is in the "User menu" all product links, both Music and Sounds, redirect to the Music menu page.

We used the "Force a menu on the checkout" option to properly display the Cart in the User / Cart menu but that doesn't prevent all products linking to the content menu for music and showing up under the Music menu, when the name in the cart is clicked.

There is no "menu" selection in the cart module similar to the product and category content menus.

To experience what I mean you can add a product to the cart (you don't have to sign up) for example you can add this one:
www.spinboom.com/index.php/en/soundlibra...oduct/monster-s00455

Then proceed to the cart/checkout:
www.spinboom.com/index.php/en/user/cart

..and click the name of the product "Monster [S00455]" and it will take you here:
www.spinboom.com/index.php/en/categories/product/monster-s00455

This is wrong as this is a Sound product. How could we change that link to:
www.spinboom.com/index.php/en/soundlibra...oduct/monster-s00455

Please help!

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

  • Posts: 83937
  • Thank you received: 13599
  • MODERATOR
10 years 4 months ago #189001

Hi,

To do that, you should update HikaShop and set the "Force canonical URLs on listings" option to "Use canonical URL and generate it if missing" in the HikaShop configuration.
That way, during the products listing display, the canonical URL of your products will be saved in the product data if not already filled, and the cart will use that URL for the link of the product automatically.

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

  • Posts: 18
  • Thank you received: 0
10 years 4 months ago #189249

Hey Nicolas,

I would like to avoid using canonical URLs if possible. Is there a way to change the cart.php file so that the listing is displayed "in place" under the same menu the cart is displayed?

The reason why I want to avoid canonical urls is that they are behaving strangely on my live site. They tend to point my server address and not the relative address. meaning that /index.php... in the canonical URL in the products is not pointing to www.spinboom.com/index.php but to www.spinboom.com/SERVERNAME/index.php

Also there seems to be canonical URL information in my product variants left there from when the website was in a local server. I can not access those fields from Joomla/Hikashop but I can see that the fields have values through phpmyadmin and that they point to the wrong address of my old localserver. Can I edit that out only through phpMyAdmin or is there a way to fix that from the Joomla Hikashop back end?

Thank you.

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

  • Posts: 83937
  • Thank you received: 13599
  • MODERATOR
10 years 4 months ago #189308

Hi,

You can edit the cart view file and force the Itemid parameter in the URL of the products to be the id of the menu you want to use instead of the current itemid of the checkout page.

I remember that we fixed issues with such subfolder issue in the URLs in previous versions of HikaShop. So it's probably because you have an old version of HikaShop that you have that issue.
No one reported such issue with the latest versions of HikaShop.

If you want to empty the canonical URLs of all the variants, you can create a new mass action via the menu System>Mass actions with filter on the product type to only process the variants, and an action "update the values" on the product_canonical column.
Once you click the "process" button it will remove them from your variants.
You can read more about mass actions here:
www.hikashop.com/support/support/documen...massaction-form.html

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

  • Posts: 18
  • Thank you received: 0
10 years 3 months ago #194634

Hey Nicolas,

I ended up replacing this code in checkout/cart view:

<?php if(@$defaultParams['link_to_product_page']){ ?><a class="hikashop_no_print" href="<?php echo hikashop_contentLink('product&task=show&cid='.$row->product_id.'&name='.$row->alias.$url_itemid,$row);?>" ><?php } ?>

with this one:
<?php if(@$defaultParams['link_to_product_page']){ ?><a class="hikashop_no_print" href="<?php echo hikashop_completeLink('product&task=show&cid='.$row->product_id.'&name='.$row->alias.$url_itemid);?>" ><?php } ?>

So, the product loads in place in the checkout menu. Same goes for the downloads area, product links load in place in the downloads menu item so it's more cohesive this way.

What do you think? We have tested it extensively and works fine, but do you think this is going to create a problem in the cart or anywhere else?

Thanks!

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

  • Posts: 83937
  • Thank you received: 13599
  • MODERATOR
10 years 3 months ago #194742

Hi,

That's a possibility yes. I don't see why it would create a problem. I don't see any problem with that change.

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

Time to create page: 0.065 seconds
Powered by Kunena Forum