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

#   checkout inconsistency

##

- **[issa.mouawad](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile")**
- [![issa.mouawad's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile") Topic Author
- [ Offline](/forum/user/38443-issa-mouawad)

Less More

- Posts: 26
- Thank you received: 0
-
-

10 years 5 months ago -  10 years 5 months ago [\#238285](#238285) by [issa.mouawad](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile")  *[checkout inconsistency](/forum/27-checkout/884162-checkout-inconsistency#238285 "-- HikaShop version -- : 2.6.2 -- Joomla version -- : 3.4.8  Hi. I am customizing a 2-step checkout flow (login,address)(shipping,cart,payment) I have come across the mentioned issue here   www.hikashop.com/forum/checkout/874042-h...in-address-step.html  (the need to submit the address in a different button than the &quot;Next&quot; button related to checkout steps)  I tried to encounter this issue by disabling &quot;Require address on registration&quot;, now registration only asks for email , upon pressing next, the checkout displays both billing and shipping addresses, here comes the problems, if you enter them and press next, you will stay on the same page and it displays the addresses with the option of adding new or removing the current addresses, even worse, you can actually add the address by pressing the &quot;Tick&quot; button in the top of the address div , which will add and display the address with a &quot;radiobutton&quot; so you select the address , and check&quot;shipping same as billing&quot; , and press next, suddenly you stay in the same page with no changes in the page at all ! (because you already see the addresses added) I think it's a bug in the checkout flow, please I appreciate any help in fixing this bug")* was created by *[issa.mouawad](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile")*

-- HikaShop version -- : 2.6.2
-- Joomla version -- : 3.4.8

Hi.
I am customizing a 2-step checkout flow (login,address)(shipping,cart,payment)
I have come across the mentioned issue here [ www.hikashop.com/forum/checkout/874042-h...in-address-step.html](http://www.hikashop.com/forum/checkout/874042-how-to-remove-next-btn-in-address-step.html) (the need to submit the address in a different button than the "Next" button related to checkout steps)

I tried to encounter this issue by disabling "Require address on registration", now registration only asks for email , upon pressing next, the checkout displays both billing and shipping addresses,
here comes the problems, if you enter them and press next, you will stay on the same page and it displays the addresses with the option of adding new or removing the current addresses,
even worse, you can actually add the address by pressing the "Tick" button in the top of the address div , which will add and display the address with a "radiobutton" so you select the address , and check"shipping same as billing" , and press next, suddenly you stay in the same page with no changes in the page at all ! (because you already see the addresses added)
I think it's a bug in the checkout flow, please I appreciate any help in fixing this bug

Last edit: 10 years 5 months ago by [issa.mouawad](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtL2NoZWNrb3V0Lzg4NDE2Mi1jaGVja291dC1pbmNvbnNpc3RlbmN5P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) 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)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86283
- Thank you received: 14262
-
-

10 years 5 months ago [\#238333](#238333) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[checkout inconsistency](/forum/27-checkout/884162-checkout-inconsistency#238333 "-- HikaShop version -- : 2.6.2 -- Joomla version -- : 3.4.8  Hi. I am customizing a 2-step checkout flow (login,address)(shipping,cart,payment) I have come across the mentioned issue here   www.hikashop.com/forum/checkout/874042-h...in-address-step.html  (the need to submit the address in a different button than the &quot;Next&quot; button related to checkout steps)  I tried to encounter this issue by disabling &quot;Require address on registration&quot;, now registration only asks for email , upon pressing next, the checkout displays both billing and shipping addresses, here comes the problems, if you enter them and press next, you will stay on the same page and it displays the addresses with the option of adding new or removing the current addresses, even worse, you can actually add the address by pressing the &quot;Tick&quot; button in the top of the address div , which will add and display the address with a &quot;radiobutton&quot; so you select the address , and check&quot;shipping same as billing&quot; , and press next, suddenly you stay in the same page with no changes in the page at all ! (because you already see the addresses added) I think it's a bug in the checkout flow, please I appreciate any help in fixing this bug")*

Hi,

Change the code: Code:

if($shipping!=$oldShippingAddress){ $cart = $this-&gt;initCart(); if($cart-&gt;has_shipping){ $this-&gt;cart_update=true; if(strpos($this-&gt;checkout_workflow,'shipping')!==false){ $this-&gt;before_shipping(true); } if(strpos($this-&gt;checkout_workflow,'payment')!==false){ $this-&gt;before_payment(true); } return false; } } if($billing!=$oldBillingAddress){ return false; }

to:
Code:

if($shipping!=$oldShippingAddress){ $cart = $this-&gt;initCart(); if($cart-&gt;has_shipping){ $this-&gt;cart_update=true; if(strpos($this-&gt;checkout_workflow,'shipping')!==false){ $this-&gt;before_shipping(true); } if(strpos($this-&gt;checkout_workflow,'payment')!==false){ $this-&gt;before_payment(true); } return true; } } if($billing!=$oldBillingAddress){ return true; }

in the file components/com_hikashop/controllers/checkout.php and it will go to the next step when you click on the next button.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtL2NoZWNrb3V0Lzg4NDE2Mi1jaGVja291dC1pbmNvbnNpc3RlbmN5P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[issa.mouawad](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile")**
- [![issa.mouawad's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile") Topic Author
- [ Offline](/forum/user/38443-issa-mouawad)

Less More

- Posts: 26
- Thank you received: 0
-
-

10 years 5 months ago [\#239859](#239859) by [issa.mouawad](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile")  Replied by *[issa.mouawad](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile")* on topic *[checkout inconsistency](/forum/27-checkout/884162-checkout-inconsistency#239859 "-- HikaShop version -- : 2.6.2 -- Joomla version -- : 3.4.8  Hi. I am customizing a 2-step checkout flow (login,address)(shipping,cart,payment) I have come across the mentioned issue here   www.hikashop.com/forum/checkout/874042-h...in-address-step.html  (the need to submit the address in a different button than the &quot;Next&quot; button related to checkout steps)  I tried to encounter this issue by disabling &quot;Require address on registration&quot;, now registration only asks for email , upon pressing next, the checkout displays both billing and shipping addresses, here comes the problems, if you enter them and press next, you will stay on the same page and it displays the addresses with the option of adding new or removing the current addresses, even worse, you can actually add the address by pressing the &quot;Tick&quot; button in the top of the address div , which will add and display the address with a &quot;radiobutton&quot; so you select the address , and check&quot;shipping same as billing&quot; , and press next, suddenly you stay in the same page with no changes in the page at all ! (because you already see the addresses added) I think it's a bug in the checkout flow, please I appreciate any help in fixing this bug")*

Hi , I am actually struggling with the same issue,
I need to simplify the flow and enable the next step only if "Next" is clicked
that is, I want the "after address" method in the checkout controller to return true only if "next" was clicked (not by selecting the radio button or anything)
I thought I could add a hidden field and set that field's value in the "next" click handler, and then check in the "after address" if this field has a certain value,
I have the scenario in my head but I need a little help on the implementation(like which view to add the hidden field in, how to inject the javascript in the 'next' click)

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtL2NoZWNrb3V0Lzg4NDE2Mi1jaGVja291dC1pbmNvbnNpc3RlbmN5P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) 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)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86283
- Thank you received: 14262
-
-

10 years 5 months ago [\#239863](#239863) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[checkout inconsistency](/forum/27-checkout/884162-checkout-inconsistency#239863 "-- HikaShop version -- : 2.6.2 -- Joomla version -- : 3.4.8  Hi. I am customizing a 2-step checkout flow (login,address)(shipping,cart,payment) I have come across the mentioned issue here   www.hikashop.com/forum/checkout/874042-h...in-address-step.html  (the need to submit the address in a different button than the &quot;Next&quot; button related to checkout steps)  I tried to encounter this issue by disabling &quot;Require address on registration&quot;, now registration only asks for email , upon pressing next, the checkout displays both billing and shipping addresses, here comes the problems, if you enter them and press next, you will stay on the same page and it displays the addresses with the option of adding new or removing the current addresses, even worse, you can actually add the address by pressing the &quot;Tick&quot; button in the top of the address div , which will add and display the address with a &quot;radiobutton&quot; so you select the address , and check&quot;shipping same as billing&quot; , and press next, suddenly you stay in the same page with no changes in the page at all ! (because you already see the addresses added) I think it's a bug in the checkout flow, please I appreciate any help in fixing this bug")*

Hi,

If you want to add your check in the after address, you want to add the hidden input in the file "address" of the view "checkout".
The next button is displayed in the file "step" of the view "checkout". I suppose that you'll want to add your custom JS before: Code:

document.forms[\'hikashop_checkout_form\'].submit();

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtL2NoZWNrb3V0Lzg4NDE2Mi1jaGVja291dC1pbmNvbnNpc3RlbmN5P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[issa.mouawad](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile")**
- [![issa.mouawad's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile") Topic Author
- [ Offline](/forum/user/38443-issa-mouawad)

Less More

- Posts: 26
- Thank you received: 0
-
-

10 years 5 months ago [\#239906](#239906) by [issa.mouawad](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile")  Replied by *[issa.mouawad](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile")* on topic *[checkout inconsistency](/forum/27-checkout/884162-checkout-inconsistency#239906 "-- HikaShop version -- : 2.6.2 -- Joomla version -- : 3.4.8  Hi. I am customizing a 2-step checkout flow (login,address)(shipping,cart,payment) I have come across the mentioned issue here   www.hikashop.com/forum/checkout/874042-h...in-address-step.html  (the need to submit the address in a different button than the &quot;Next&quot; button related to checkout steps)  I tried to encounter this issue by disabling &quot;Require address on registration&quot;, now registration only asks for email , upon pressing next, the checkout displays both billing and shipping addresses, here comes the problems, if you enter them and press next, you will stay on the same page and it displays the addresses with the option of adding new or removing the current addresses, even worse, you can actually add the address by pressing the &quot;Tick&quot; button in the top of the address div , which will add and display the address with a &quot;radiobutton&quot; so you select the address , and check&quot;shipping same as billing&quot; , and press next, suddenly you stay in the same page with no changes in the page at all ! (because you already see the addresses added) I think it's a bug in the checkout flow, please I appreciate any help in fixing this bug")*

Thanks ! it all works now ..
I actually need another help too,
I want to initially display shipping address form if the user is guest and nb_addresses =1 , (I want the default interaction, that the guest user adds a shipping address different than the billing address , unless of course he wants to tick the "same address" check)
I figured out how to do the checks (check if user is guest and nb_addresses=1)
but I don't know how to convert the shipping address area to "add" mode , I tried in view "address/select" maybe I it's another view I should place the logic in ?

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtL2NoZWNrb3V0Lzg4NDE2Mi1jaGVja291dC1pbmNvbnNpc3RlbmN5P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) 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)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86283
- Thank you received: 14262
-
-

10 years 5 months ago [\#239909](#239909) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[checkout inconsistency](/forum/27-checkout/884162-checkout-inconsistency#239909 "-- HikaShop version -- : 2.6.2 -- Joomla version -- : 3.4.8  Hi. I am customizing a 2-step checkout flow (login,address)(shipping,cart,payment) I have come across the mentioned issue here   www.hikashop.com/forum/checkout/874042-h...in-address-step.html  (the need to submit the address in a different button than the &quot;Next&quot; button related to checkout steps)  I tried to encounter this issue by disabling &quot;Require address on registration&quot;, now registration only asks for email , upon pressing next, the checkout displays both billing and shipping addresses, here comes the problems, if you enter them and press next, you will stay on the same page and it displays the addresses with the option of adding new or removing the current addresses, even worse, you can actually add the address by pressing the &quot;Tick&quot; button in the top of the address div , which will add and display the address with a &quot;radiobutton&quot; so you select the address , and check&quot;shipping same as billing&quot; , and press next, suddenly you stay in the same page with no changes in the page at all ! (because you already see the addresses added) I think it's a bug in the checkout flow, please I appreciate any help in fixing this bug")*

Hi,

Changing the address area can be done like in the address/show view file which such javascript: Code:

window.addressMgr.update&lt;?php echo ucfirst($this-&gt;type);?&gt; = function() { window.Oby.xRequest('&lt;?php echo hikashop_completeLink('address&amp;task=show&amp;subtask='.$this-&gt;type.'_address&amp;cid='.$this-&gt;address_id, true, false, true); ?&gt;',{update:'&lt;?php echo $this-&gt;fieldset_id; ?&gt;'}); };

So it's just a call to xRequest with the link for the edit/show subtask, the id of the address and the update parameter with the id of the HTML element to be updated.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtL2NoZWNrb3V0Lzg4NDE2Mi1jaGVja291dC1pbmNvbnNpc3RlbmN5P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[issa.mouawad](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile")**
- [![issa.mouawad's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile") Topic Author
- [ Offline](/forum/user/38443-issa-mouawad)

Less More

- Posts: 26
- Thank you received: 0
-
-

10 years 5 months ago [\#240018](#240018) by [issa.mouawad](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile")  Replied by *[issa.mouawad](/forum/user/38443-issa-mouawad "View issa.mouawad's Profile")* on topic *[checkout inconsistency](/forum/27-checkout/884162-checkout-inconsistency#240018 "-- HikaShop version -- : 2.6.2 -- Joomla version -- : 3.4.8  Hi. I am customizing a 2-step checkout flow (login,address)(shipping,cart,payment) I have come across the mentioned issue here   www.hikashop.com/forum/checkout/874042-h...in-address-step.html  (the need to submit the address in a different button than the &quot;Next&quot; button related to checkout steps)  I tried to encounter this issue by disabling &quot;Require address on registration&quot;, now registration only asks for email , upon pressing next, the checkout displays both billing and shipping addresses, here comes the problems, if you enter them and press next, you will stay on the same page and it displays the addresses with the option of adding new or removing the current addresses, even worse, you can actually add the address by pressing the &quot;Tick&quot; button in the top of the address div , which will add and display the address with a &quot;radiobutton&quot; so you select the address , and check&quot;shipping same as billing&quot; , and press next, suddenly you stay in the same page with no changes in the page at all ! (because you already see the addresses added) I think it's a bug in the checkout flow, please I appreciate any help in fixing this bug")*

when should I add this ?
I have added the code you provided in window.onload but nothing changed
to clarify, I don't want the address to be edited , but rather to add a new one , so I thought I should use
return window.localPage.switchAddr(0, 'shipping');
any help on how to accomplish that?

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtL2NoZWNrb3V0Lzg4NDE2Mi1jaGVja291dC1pbmNvbnNpc3RlbmN5P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) 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)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Away](/forum/user/63-nicolas)

Less More

- Posts: 86283
- Thank you received: 14262
-
-

10 years 5 months ago [\#240019](#240019) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[checkout inconsistency](/forum/27-checkout/884162-checkout-inconsistency#240019 "-- HikaShop version -- : 2.6.2 -- Joomla version -- : 3.4.8  Hi. I am customizing a 2-step checkout flow (login,address)(shipping,cart,payment) I have come across the mentioned issue here   www.hikashop.com/forum/checkout/874042-h...in-address-step.html  (the need to submit the address in a different button than the &quot;Next&quot; button related to checkout steps)  I tried to encounter this issue by disabling &quot;Require address on registration&quot;, now registration only asks for email , upon pressing next, the checkout displays both billing and shipping addresses, here comes the problems, if you enter them and press next, you will stay on the same page and it displays the addresses with the option of adding new or removing the current addresses, even worse, you can actually add the address by pressing the &quot;Tick&quot; button in the top of the address div , which will add and display the address with a &quot;radiobutton&quot; so you select the address , and check&quot;shipping same as billing&quot; , and press next, suddenly you stay in the same page with no changes in the page at all ! (because you already see the addresses added) I think it's a bug in the checkout flow, please I appreciate any help in fixing this bug")*

Mmm. I'm not sure what you mean by add a new one.
The window.addressMgr.updateShipping and window.addressMgr.updateBilling javascript functions are to refresh the billing/shipping area.
The window.localPage.switchAddr function is to change the selected shipping/billing address.
Adding a new address requires using the window.hikashop.form(this,'&lt;?php echo $this-&gt;fieldset_id; ?&gt;'); function call like it's done in the onclick of the save button in address/show with the hidden input field with the name data[address_id] having a value of 0 instead of an address_id.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtL2NoZWNrb3V0Lzg4NDE2Mi1jaGVja291dC1pbmNvbnNpc3RlbmN5P3RtcGw9bWFya2Rvd24=) or [Create an account](/component/users/registration?Itemid=101) 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.236 seconds

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

[](#top)
