Shipping forgotten when first address is entered

  • Posts: 76
  • Thank you received: 2
  • Hikashop Business
11 years 2 months ago #148084

I use a different registration form to Hikashop's because my site is also a social network. This registration process does not include an address, so I was delighted to see that when a user checkout's out who hasn't already specified a Hikashop address, Hikashop pops up a nice little box saying, "please fill in an address". The problem is that when this is done, the previously filled out shipping info is lost and has to be reentered, confusing the process rather.

To clarify - my checkout process is: shipping, login, address, payment. So a user can fill out shipping, log into Hikashop for the first time, get the address popup (with the shipping info still visible in the background), but as soon as the user clicks Ok on the address pop-up, this shipping info is lost and they are required to re-enter it and step through the checkout from stage one again.

Is there an easy (ish) fix to this. I don't mind hacking some php if you could point me in the right direction. What might be causing this?

-- url of the page with the problem -- : claycellar.co.uk
-- HikaShop version -- : 2.3.0
-- Joomla version -- : 2.5.14

Many thanks,

Jonathan

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

  • Posts: 13201
  • Thank you received: 2322
11 years 2 months ago #148217

Hi,
Since HikaShop 2.3.0 you can change the way the address must be filled.
You have to change the value of the option "Address selector" in Configuration > Checkout > Shipping & Payment.

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

  • Posts: 76
  • Thank you received: 2
  • Hikashop Business
11 years 2 months ago #148278

Hi Xavier,

Thanks for this, using a different address input method does solve the problem.

But I quite like the pop-up method and have already formatted the site to use the popup method. Is there no way of fixing it so it also works? Every time you add a new address with the popup, the shipping information is lost. This surely shouldn't happen?

Jonathan

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

  • Posts: 76
  • Thank you received: 2
  • Hikashop Business
11 years 2 months ago #148338

I appear to have solved the problem by deleting lines 196-198 of the file: components/com_hikashop/controllers/address.php, which are:

$app->setUserState(HIKASHOP_COMPONENT.'.shipping_data', null);
		$app->setUserState(HIKASHOP_COMPONENT.'.shipping_method', null);
		$app->setUserState(HIKASHOP_COMPONENT.'.shipping_id', null);

I was wondering whether you could comment on whether there could be any unwanted negative effects from doing this?Why are these lines there? And why don't they cause the shipping to be deleted when using the dropdown list display option for addresses?

Best wishes,

Jonathan

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

  • Posts: 26251
  • Thank you received: 4040
  • MODERATOR
11 years 2 months ago #148339

Hi,

The "problem" is that the customer addresses changed and HikaShop reset at this moment the shipping.
Because a part of the customer configuration changed, we have to reprocess the shippings in order to know if they are still available for the customer. During this process, the shipping are reset and because you put the shipping before the address, HikaShop have to revalidate it.

In your case, if you are sure that the shipping methods won't change, you can let your patch.
But for most of cases, when the addresses changed, the shipping methods can change, so we clean it to force the shipping reprocessing.

That's why we recommend to put the "address" before the "shipping".

Regards,


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

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

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

Time to create page: 0.073 seconds
Powered by Kunena Forum