add to cart not working

  • Posts: 13
  • Thank you received: 0
14 years 3 weeks ago #2859

Hi there.
I've been used hikashop for my website shopping cart. The problem is: 'add to cart' button can't work like while i was used it in my localhost server. Are there any solution for this problem?
While i click add to cart button, the page was refreshed into blank page that contain previous category title. I can't continue to the checkout page.
I can't fix it. Thank you.

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

  • Posts: 83024
  • Thank you received: 13403
  • MODERATOR
14 years 3 weeks ago #2860

Hi,

Could you give a link to your website so that we can have a look at the problem ?

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

  • Posts: 13
  • Thank you received: 0
14 years 3 weeks ago #2861


I change 'add to cart' words with 'pinjam'. When i clicked it, the page reloading a blank page and display previous title in page. Thank you.

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

  • Posts: 13
  • Thank you received: 0
14 years 3 weeks ago #2862

wetick.com/index.php?option=com_hikashop...4&category_pathway=0
I'm sorry, there's some trouble in my server so i reply again with web link.

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

  • Posts: 83024
  • Thank you received: 13403
  • MODERATOR
14 years 3 weeks ago #2863

It seems that you added the add to cart button yourself in the description of the product. However, the link of the add to cart button is not valid. It is:
wetick.com/index.php?option=com_hikashop...oduct_id=0&Itemid=54
Where It should be:
wetick.com/index.php?option=com_hikashop...oduct_id=6&Itemid=54
You can correct that by editing the product description.

Normally, the "add to cart" button is handled automatically by HikaShop. However, if the stock of the product is 0, or if the product start sale date is in the future, or if the product end sale date in on the past, or if the "catalogue mode" of the tab display in the configuration is set to on, the "add to cart" button will be hidden from the product page. Moreover, the text of the button can easily be changed by editing the translation file under the tab languages of the configuration. You shoul not have to add that button yourself, although it is possible.

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

  • Posts: 13
  • Thank you received: 0
14 years 3 weeks ago #2864

Thanks for your solution nicholas. That's absolutely help me.
I've been using language tab to translate, but it didn't same with the meaning of that word in my language. So i change it into my language.
But i want to ask more question, how could the product_id value change into 0? I've been looking into hikashop product in my localhost server, the product_id still in 'add to cart html link' still same with the actual product_id. But it works. Why it not works in wetick.com/index.php?option=com_hikashop...t_id=0&Itemid=54?
I'm sorry to ask more question, but i'm still curious.
Anyway, thanks a lot.

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

  • Posts: 83024
  • Thank you received: 13403
  • MODERATOR
14 years 3 weeks ago #2865

The value of the product_id variable in the link "add to cart" need to be the id of the product (you will see it on the listing of products on the right end of the listing). If the value of product_id is 0, it means that you are asking the system to add the product with the id 0 to the cart. Or that product doesn't exist, which is why you don't go to the checkout.
Normally, you should get an error message displayed at that point, but if your template is missing the jdoc include message tag, it won't be displayed: www.hikashop.com/en/support/documentation/61.html

The product_id will be 0 on the "add to cart html link" button popup only when you create a new porduct. That is because when you create a new product, the id for the product does not yet exists. We are going to change that to hide the "add to cart html link" button when the product is a new product and only display it for products already existing. That will avoid having other persons doing the same mistake.

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

Time to create page: 0.062 seconds
Powered by Kunena Forum