Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Marc-André 63 posts 276 karma points
    Feb 20, 2020 @ 17:44
    Marc-André
    0

    Prevent page from refreshing after a form is submited

    Hello!

    In Umbraco Forms, I want to display a message instead of redirect to a confirmation page. The page still refresh and then I see my confirmation message. Sinc emy form is in a modal, I don't want my page to refresh.

    How can I achieve that?

    Thanks Umbraco community!

  • Andy Shokry 5 posts 75 karma points
    Apr 15, 2020 @ 14:58
    Andy Shokry
    0

    I would like to know the answer to this as well. Everything seems to work, except the page is refreshed when the form is submitted.

    Umbraco Forms 7.3.1

  • Yakov Lebski 427 posts 1654 karma points
    Apr 28, 2020 @ 15:34
    Yakov Lebski
    0

    you can just do ajax call instead of regular submit

    $.ajax({
        url: $form.attr('action'),
        type: 'POST',
        cache: false,
        data: $form.serialize(),
        success: function (result, textStatus, request) {
            //Show popup here
        }
    });
    
  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies