[Skip to main content](#vessel-content)

#   Error on add to cart and remove from mini cart

##

- **[dustinjc](/forum/user/31466-dustinjc "View dustinjc's Profile")**
- [![dustinjc's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar31466.jpg)](/forum/user/31466-dustinjc "View dustinjc's Profile") Topic Author
- [ Offline](/forum/user/31466-dustinjc)

Less More

- Posts: 176
- Thank you received: 5
-
-

4 years 6 months ago [\#340762](#340762) by [dustinjc](/forum/user/31466-dustinjc "View dustinjc's Profile")  *[Error on add to cart and remove from mini cart](/forum/27-checkout/904236-error-on-add-to-cart-and-remove-from-mini-cart#340762 "-- HikaShop version -- : 4.5.0 -- Joomla version -- : 3.10.6 -- PHP version -- : 7.4.28  I'm getting javascript errors when trying to add to cart or remove items from a saved cart via the mini cart. Any ideas? This is occurring for all users.  Screenshot:   www.evernote.com/l/ACjPLan1KpdGpJmV0wey7kIi70Zy0o2&#95;3Ik")* was created by *[dustinjc](/forum/user/31466-dustinjc "View dustinjc's Profile")*

-- HikaShop version -- : 4.5.0
-- Joomla version -- : 3.10.6
-- PHP version -- : 7.4.28

I'm getting javascript errors when trying to add to cart or remove items from a saved cart via the mini cart. Any ideas? This is occurring for all users.

Screenshot:
[ www.evernote.com/l/ACjPLan1KpdGpJmV0wey7kIi70Zy0o2\_3Ik](https://www.evernote.com/l/ACjPLan1KpdGpJmV0wey7kIi70Zy0o2_3Ik)

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0LzkwNDIzNi1lcnJvci1vbi1hZGQtdG8tY2FydC1hbmQtcmVtb3ZlLWZyb20tbWluaS1jYXJ0P3RtcGw9bWFya2Rvd24=) or [Create an account](/register) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86324
- Thank you received: 14285
-
-

4 years 6 months ago [\#340763](#340763) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Error on add to cart and remove from mini cart](/forum/27-checkout/904236-error-on-add-to-cart-and-remove-from-mini-cart#340763 "-- HikaShop version -- : 4.5.0 -- Joomla version -- : 3.10.6 -- PHP version -- : 7.4.28  I'm getting javascript errors when trying to add to cart or remove items from a saved cart via the mini cart. Any ideas? This is occurring for all users.  Screenshot:   www.evernote.com/l/ACjPLan1KpdGpJmV0wey7kIi70Zy0o2&#95;3Ik")*

Hi,

If you look at the response from the server for the AJAX add to cart request with your browser's developers tool you can see this:
[ i.imgur.com/2OyGT7b.png](https://i.imgur.com/2OyGT7b.png)Code:

0 Call to undefined method hikashopCartClass::getCartProductsInfo()

This function getCartProductsInfo is defined in the file administrator/components/com_hikashop/classes/cart.php and is used at only one place in HikaShop, in the file components/com_hikashop/controllers/product.php
Both are core files of HikaShop and that this function definitely exists (or the add to cart wouldn't work for anyone using HikaShop since the 4.5.0 has been released) in administrator/components/com_hikashop/classes/cart.php in the latest version of HikaShop (which you have).
So the only conclusion is that either the file administrator/components/com_hikashop/classes/cart.php was modified to remove that function (which I suppose isn't the case, or you would have figured out it came from your modifications), or that you're using an old version of the file administrator/components/com_hikashop/classes/cart.php. This could happen if the joomla installer couldn't replace the file during the update process because of wrong permissions on that file. In that case, you could delete the file and redo an install of the HikaShop install package to add back to correct version of that file.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0LzkwNDIzNi1lcnJvci1vbi1hZGQtdG8tY2FydC1hbmQtcmVtb3ZlLWZyb20tbWluaS1jYXJ0P3RtcGw9bWFya2Rvd24=) or [Create an account](/register) to join the conversation.

- **[dustinjc](/forum/user/31466-dustinjc "View dustinjc's Profile")**
- [![dustinjc's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar31466.jpg)](/forum/user/31466-dustinjc "View dustinjc's Profile") Topic Author
- [ Offline](/forum/user/31466-dustinjc)

Less More

- Posts: 176
- Thank you received: 5
-
-

4 years 6 months ago [\#340780](#340780) by [dustinjc](/forum/user/31466-dustinjc "View dustinjc's Profile")  Replied by *[dustinjc](/forum/user/31466-dustinjc "View dustinjc's Profile")* on topic *[Error on add to cart and remove from mini cart](/forum/27-checkout/904236-error-on-add-to-cart-and-remove-from-mini-cart#340780 "-- HikaShop version -- : 4.5.0 -- Joomla version -- : 3.10.6 -- PHP version -- : 7.4.28  I'm getting javascript errors when trying to add to cart or remove items from a saved cart via the mini cart. Any ideas? This is occurring for all users.  Screenshot:   www.evernote.com/l/ACjPLan1KpdGpJmV0wey7kIi70Zy0o2&#95;3Ik")*

It was related to the customizations we had you do. I had failed to fully apply the patch to the cart.php on this website but didn't realize it. I've re-applied the patch and it is now working correctly. Thank you for steering me in the right direction!

The following user(s) said Thank You: [Philip](/forum/user/34318-philip "View Philip's Profile")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzI3LWNoZWNrb3V0LzkwNDIzNi1lcnJvci1vbi1hZGQtdG8tY2FydC1hbmQtcmVtb3ZlLWZyb20tbWluaS1jYXJ0P3RtcGw9bWFya2Rvd24=) or [Create an account](/register) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.088 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
