Checkout registration automatically scroll to top when user error

  • Posts: 200
  • Thank you received: 75
6 years 3 months ago #285820

-- HikaShop version -- : 3.2.2
-- Joomla version -- : 3.8.3

Hi,

during checkout registration when a user doesn't enter all his data correctly, the error messages will appear at the top of the form. Especially on small screens such as on mobile devices this can be a problem since the register/continue button is all the way at the bottom and the errors are out of view from the user, and they may have no idea why the register button isn't working or doesn't seem to do anything.

Would it be possible when the user clicks on the register/continue button but has made a mistake, to automatically scroll back to the top to where the error messages are displayed? That would be a great improvement.


Also, if the registration page reloads because not all fields are entered correctly some browsers show a Javascript error in the developer tools:
Object doesn't support property or method 'forEach'
File: media/com_hikashop/js/checkout.js, Line: 134, Column: 3

Thanks for any help.

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

  • Posts: 26007
  • Thank you received: 4004
  • MODERATOR
6 years 3 months ago #285863

Hello,

Can you please provide a link to your website so we can check the JS error and understand more about the usage context ?

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.

  • Posts: 200
  • Thank you received: 75
6 years 3 months ago #285876

Hi,

you can see what I mean on the demo website as well, we don't think it's related to our website.
Just add any product, go to checkout and click on register while leaving some fields empty. Chrome doesn't appear to show the JS error, but for example Edge or IE (we know it's IE, but still the third most used browser) will have it, see also attached image.


Regarding our question though, when a user clicks register, the checkout page will briefly process the form and some error messages will be added at the top of the page, but the page will stay exactly where it was, at the bottom of the form where the error messages are completely out of view.
It may seem logical to just scroll back up, but from experience we can say there are many customers who really do not understand that and simply leave because nothing appears to happen when they click the button and they think the checkout is broken or faulty. So if the page could automatically scroll back to the top, that would be much better to avoid any confusion with customers.

Thanks.

Attachments:

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

  • Posts: 26007
  • Thank you received: 4004
  • MODERATOR
6 years 3 months ago #285879

Hello,

If I'm asking you a website it's for a good reason ; like knowing the version number you're using and check if you have all latest patches or not.

Regarding the JS error, now that I can see that you're using Internet Explorer ; I have the required information to deduce that IE do not handle "forEach" on the result of the function querySelectorAll.

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.059 seconds
Powered by Kunena Forum