Navigation
This is archived content. Visit our new forum.
  • Author
    Posts
  • #255107
    Misho
    Participant

    Hi,

    I cannot make this work, can you please help me!

    I have an embed code for a Typeform survey:

    <a class="typeform-share link" href="https://example.typeform.com/to/vGiopM?source=xxxxx&position=xxxxx" data-mode="1" target="_blank">Button link</a>
    <script>(function(){var qs,js,q,s,d=document,gi=d.getElementById,ce=d.createElement,gt=d.getElementsByTagName,id='typef_orm',b='https://s3-eu-west-1.amazonaws.com/share.typeform.com/';if(!gi.call(d,id)){js=ce.call(d,'script');js.id=id;js.src=b+'share.js';q=gt.call(d,'script')[0];q.parentNode.insertBefore(js,q)}})()</script>

    This should open the form in a popup – not navigate away to the form page.
    I have put the Javascript into the customizer and it works from there, which left me with this code:

    <a class="typeform-share link" href="https://example.typeform.com/to/vGiopM?source=xxxxx&position" data-mode="1" target="_blank">Button link</a>

    This works well as a link. However, I want to trigger it from X-button. I have tried to place the link into the Href, and the typeform-share link into the Class field.

    I have tried to add the data-mode="1" manually in the classic editor, but just cannot make it work.

    This is the shortcode that does not work:

    [vc_column width="1/3"][button shape="rounded" size="regular" float="none" info="none" info_place="top" info_trigger="hover" href="https://example.typeform.com/to/vGiopM?izvor=xxxxx&pozicija=xxxxx" target="_blank data-mode="1" class="typeform-share link"]Button form[/button][/vc_column][vc_column width="1/3"][/vc_column]
    

    I will have a lot of these buttons throughout the website, the only difference will be the part behind the “?” which is for analytics purposes.

    Do you have an idea how to make this work?

    Thank you!

    #255110
    Misho
    Participant
    This reply has been marked as private.
    #255306
    Lely
    Moderator
    #255560
    Misho
    Participant

    Hi,

    thanks, I have checked that, but it was not what I needed.

    Anyway, I have just managed to make it work:

    I have replaced their class button with this: x-btn w-500 x-btn-rounded x-btn-regular alignleft, and instead of using button shortcode, I am using the text shortcode for pasting their code in.

    Thank you!

    #255649
    Zeshan
    Member

    Glad to hear you’ve figured it out! 🙂

  • <script> jQuery(function($){ $("#no-reply-255107 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>