Change add to cart button to view product?

  • Posts: 14
  • Thank you received: 0
10 years 2 weeks ago #212782

-- HikaShop version -- : 2.5.0
-- Joomla version -- : 3.4.3

Hi

How can we change the default message and link "add to cart" that appears athe the module display for hikashop products for a: "view product" button, people want to see the hole description, theay wont buy just for the picture and short info, thats why i need that change

Thanks

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

  • Posts: 84308
  • Thank you received: 13701
  • MODERATOR
10 years 2 weeks ago #212799

Hi,

You want to turn off the display of the add to cart buttons in the settings of your products listing module (via the menu Display>Content modules).
Then, you can edit the file "listing_img_title" for the "product" view via the menu Display>Views and add such code near the end:

<input type="button" onclick="window.location='<?php echo $link; ?>'; return false;" value="View product" />

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

  • Posts: 281
  • Thank you received: 7
  • Hikamarket Frontedition Hikamarket Multivendor Hikaserial Standard Hikashop Business
9 years 4 months ago #237170

This solution worked great, but is there some way to still have the "Out Of Stock" text show on the product listing for the items that are sold out?

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

  • Posts: 84308
  • Thank you received: 13701
  • MODERATOR
9 years 4 months ago #237228

Hi,

In that case, you can add such code in the same view file:

<?php if($this->row->product_quantity==0) echo JText::_('NO_STOCK'); ?>

Last edit: 9 years 4 months ago by nicolas.

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

Time to create page: 0.069 seconds
Powered by Kunena Forum