Skip to main content

[SOLVED] ADDRESS Step is Skipped After Login

13 years 2 months ago - 13 years 2 months ago #123341 by MSTACE
-- url of the page with the problem -- : www.stacecosmetics.com/
-- HikaShop version -- : HikaShop Business: 2.2.1
-- Joomla version -- : Joomla! 2.5.14
-- PHP version -- : 5.3.26
-- Browser(s) name and version -- : any
-- Error-message(debug-mod must be tuned on) -- : n/a

When a returning customer goes to checkout, after they login they are then redirected to the SHIPPING step.
This is skipping the ADDRESS step which would allow them to select which address they want.
(see screenshot of our checkout steps)

Sometimes clicking on the ADDRESS step in the checkout bar will result in the LOGIN box being displayed instead of the addresses.
Last edit: 13 years 2 months ago by MSTACE.

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

13 years 2 months ago #123346 by MSTACE
Additional Info:

The customer we are having problems with has TWO shipping addresses listed in their account.

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

13 years 2 months ago #123360 by Mohamed Thelji
Hi,
firstly can you show me some screenshots of how did you configured your checkout configuration page ("HIkashop->System->Configuration->'Checkout'") ?

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

13 years 2 months ago - 13 years 2 months ago #123371 by MSTACE
Screenshot attached.

The customer deleted the 2nd address and now everything is working as should be.
Last edit: 13 years 2 months ago by MSTACE.
The following user(s) said Thank You: Mohamed Thelji

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

13 years 2 months ago #123512 by MSTACE
I just did another test with my own account.

The ADDRESS step is being skipped each time after login.

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

13 years 2 months ago #123530 by Jerome
Hi,

Please edit the controller checkout "components/com_hikashop/controllers/checkout.php" and replace the "before_login" function using this one:
Code:
function before_login(){ if(count($this->controllers) == 1) { $user = JFactory::getUser(); $app = JFactory::getApplication(); $user_id = $app->getUserState( HIKASHOP_COMPONENT.'.user_id' ); if(!$user->guest || $user_id){ $controllersCheck = trim($this->steps[$this->previous]); $controllersCheck = explode('_', $controllersCheck); $current = $this->current + 1; if(count($controllersCheck) == 1 && $controllersCheck[0] == 'login') $current = $this->previous + 1; JRequest::setVar('step', $current); JRequest::setVar('previous', 0); $this->step(); } } return true; }
It will solve the problem.

Regards,

Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

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

13 years 2 months ago #123610 by MSTACE
Yes. Perfect.

Thank you!

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

Time to create page: 0.063 seconds
Powered by Kunena Forum