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

#   Itemid is not respected

##

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

Less More

- Posts: 431
- Thank you received: 19
-
-

3 years 7 months ago [\#349861](#349861) by [neo191987](/forum/user/35364-neo191987 "View neo191987's Profile")  *[Itemid is not respected](/forum/2-general-talk-about-hikashop/906031-itemid-is-not-respected#349861 "Hi, now I do tests with Joomla 4 and found this problem. When the Empty the Cart, the page will be reloaded, but it will not retain itemid even though it is entered. In the demo with Joomla 3 works...")* was created by *[neo191987](/forum/user/35364-neo191987 "View neo191987's Profile")*

Hi, now I do tests with Joomla 4 and found this problem. When the Empty the Cart, the page will be reloaded, but it will not retain itemid even though it is entered. In the demo with Joomla 3 works properly. It may have affected the features - Set As Current Cart and Delete Cart in User control panel&gt;Carts.
Code:

hikashop_completeLink('cart&amp;task=remove&amp;cid='.$cart-&gt;cart_id.'&amp;'.hikashop_getFormToken().'=1&amp;Itemid='.$Itemid)

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzItZ2VuZXJhbC10YWxrLWFib3V0LWhpa2FzaG9wLzkwNjAzMS1pdGVtaWQtaXMtbm90LXJlc3BlY3RlZD90bXBsPW1hcmtkb3du) 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: 86322
- Thank you received: 14280
-
-

3 years 7 months ago [\#349868](#349868) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Itemid is not respected](/forum/2-general-talk-about-hikashop/906031-itemid-is-not-respected#349868 "Hi, now I do tests with Joomla 4 and found this problem. When the Empty the Cart, the page will be reloaded, but it will not retain itemid even though it is entered. In the demo with Joomla 3 works...")*

Hi,

Note that this is the URL to empty the cart. Once the cart is empty, the system will automatically redirect to the "URL where to redirect when the cart is empty" configured in the HikaShop configuration.
So check that setting. If that setting is empty, HikaShop should try to keep the current Itemid if it's a HikaShop menu item type. If not, it will automatically select another one.

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

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

Less More

- Posts: 431
- Thank you received: 19
-
-

3 years 7 months ago -  3 years 7 months ago [\#349983](#349983) by [neo191987](/forum/user/35364-neo191987 "View neo191987's Profile")  Replied by *[neo191987](/forum/user/35364-neo191987 "View neo191987's Profile")* on topic *[Itemid is not respected](/forum/2-general-talk-about-hikashop/906031-itemid-is-not-respected#349983 "Hi, now I do tests with Joomla 4 and found this problem. When the Empty the Cart, the page will be reloaded, but it will not retain itemid even though it is entered. In the demo with Joomla 3 works...")*

Hi, I want to ask if there is a way to make after executing the function to be redirected to a given url.
For example Code:

hikashop_completeLink('cart&amp;task=remove&amp;cid='.$cart-&gt;cart_id.'&amp;'.hikashop_getFormToken().'=1&amp;Itemid='.$Itemid. '&amp;redirect=another url address')

or something like this,

Last edit: 3 years 7 months ago by [neo191987](/forum/user/35364-neo191987 "View neo191987's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzItZ2VuZXJhbC10YWxrLWFib3V0LWhpa2FzaG9wLzkwNjAzMS1pdGVtaWQtaXMtbm90LXJlc3BlY3RlZD90bXBsPW1hcmtkb3du) 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: 86322
- Thank you received: 14280
-
-

3 years 7 months ago [\#349988](#349988) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Itemid is not respected](/forum/2-general-talk-about-hikashop/906031-itemid-is-not-respected#349988 "Hi, now I do tests with Joomla 4 and found this problem. When the Empty the Cart, the page will be reloaded, but it will not retain itemid even though it is entered. In the demo with Joomla 3 works...")*

Hi,

There is no direct parameter you can use for that.
However, in a plugin of the group "hikashop" or "system", you can implement the event onAfterCartDelete(&amp;$ids) and in it, you can redirect the user wherever you want before HikaShop redirects to the "URL where to redirect when the cart is empty".

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzItZ2VuZXJhbC10YWxrLWFib3V0LWhpa2FzaG9wLzkwNjAzMS1pdGVtaWQtaXMtbm90LXJlc3BlY3RlZD90bXBsPW1hcmtkb3du) 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.064 seconds

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

[](#top)
