le scroll du message de remerciement n'est pas en haut du message.

  • jerome_tayon
    Demandé le 4 septembre 2023 à 11:10

    Bonjour, 

    Je n'arrive pas à régler le scroll de la page de remerciement de mon formulaire pour qu'il affiche le début du message.

    Je peux ajouter du CSS additionnel à mon site wordpress si il le faut.

    En pièce jointe, une explication visuelle de ce que je voudrais.

    Bien cordialement

    Jotform Thread 5500996 Screenshot
  • Sonnyfer Jotform Support
    Répondu le 4 septembre 2023 à 22:27

    Hi Jérôme,

    Thanks for reaching out to Jotform Support. Unfortunately, our French Support agents are busy helping other Jotform users at the moment. I'll try to help you in English using Google Translate, but you can reply in whichever language you feel comfortable using. Or, if you'd rather have support in French, let us know and we can have them do that. But, keep in mind that you'd have to wait until they're available again.

    Now, let me help you with your question. I'm sorry you're having trouble viewing the Thank You page on your Wordpress website. Can you please share the URL of your website so we can check it from there? Also, can you allow us to test submit your embedded form to test how the Thank You page displays?

    Meantime, you can try re-embedding your form via the iFrame method and see if it makes any difference. It's easy to get it, let me show you how:

    1. In Form Builder, select Publish at the top.
    2. Next, in the left pane, go to Embed.
    3. Then select iFrame from the options.Steps to access the iframe embed code in Form Builder Screenshot 10
    4. Finally, to copy your form’s iFrame embed code, select Copy Code at the bottom.Arrow pointing to the Copy Code button in Form Builder Screenshot 21

    That's it. Keep us updated and let us know if you need any more help.

  • jerome_tayon
    Répondu le 5 septembre 2023 à 07:16

    hello, thank you for your answer.

    For sure it is ok with an iframe, because it does not open in a pop up, so there is only the scrollbar of the browser.

    But i would like to open that form in a pop up.

    In fact when clicking on the submit button :

    <button id="input_55" type="submit" class="form-submit-button submit-button jf-form-buttons jsTest-submitField" data-component="button" data-content="">Finaliser et envoyer le formulaire</button>

    the pop up load my "condition answer" whithout scrolling back to top of the popup.

    You can check and test submit there :
    https://www.eloge-mag.fr/definir-votre-cuisine-ideale/

    Cordialement
    Jérôme Tayon

  • Elton Support Team Lead
    Répondu le 7 septembre 2023 à 01:44

    Hi Jérôme,

    Thanks for getting back to us. When I tested the cloned version of your form embedded in a lightbox, I was able to replicate the issue. The lightbox window did not scroll back to the top. Please try the following solution, this might fix it. Let me show you how to set this up:

    • In your lightbox embed code, find this code:
    window.handleIFrameMessage = function(e) {
    • Then insert this code right after it:
    var frame = document.querySelector("#js-form-content iframe");
    var target = document.querySelector(".jt-content");
    var observer = new MutationObserver(function(mutationsList, observer) {
      for (var mutation of mutationsList){
      if (mutation.attributeName == "data-parent-scrolled"){
      target.scrollTo(0,0);
      }
    }
    });
    observer.observe(frame, { attributes: true});

    Here's a screenshot for reference:

    le scroll du message de remerciement nest pas en haut du message Screenshot 30

    So when you submit the form, the window will scroll back to the top showing the top portion of the thank you page. Here's a screencast that shows my test result.

    le scroll du message de remerciement nest pas en haut du message Screenshot 41

    Give it a try and let us know how it goes.

  • jerome_tayon
    Répondu le 7 septembre 2023 à 04:02

    Hi Elton,

    It is perfect!

    Thank you so much and keep the good work!