Scroll to Missing form Validator

Home Forums Quform PHP Scroll to Missing form Validator

This topic is: resolved
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #5091
    rosscoloco
    Participant

    Hey,

    I’m working on a site using your quform, and for some reason, when form validation goes through, the screen does not properly scroll to the element that was not properly validated.

    How does the scroll to javascript function work? What element does it scroll to?

    Thanks!

    ~Rossco

    #5092
    rosscoloco
    Participant

    I’m using a few other scripts.

    If you want to look at the code, please send me an email: rosslacy@gmail.com. I’m developing an app for doctors, and do not want many people seeing this initial project.

    Thanks!

    #5093
    Allan
    Support Staff

    You don't have permission to view this content. Please log in or register and then verify your purchases to gain access.

    #5150
    rosscoloco
    Participant

    This fixed it: I adjusted the size/position of the input, so the javascript needs to scroll to the input’s wrapper instead of the input.

    In the js/plugins.js file find this line:

    if (!$firstError) $firstError = $element;
    Replace with:
    if (!$firstError) $firstError = $element.closest(‘.quform-element’);

    SOLVED! Thanks support!

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.
Be inspired. © 2024 ThemeCatcher Ltd. 20-22 Wenlock Road, London, England, N1 7GU | Company No. 08120384 | Built with React | Privacy Policy