Adding a form script to a href "http://form.com"

  • Profile Image
    Tara2006
    Asked on July 31, 2015 at 12:06 AM

    I have coded a website using the bootstrap layout and the buttons are a bootstrap component, is it possible to make the bootstrap button when clicked go to my JotForm ??

    And by the way JotForms are the best, thank you for all the time and details you have put into these....

  • Profile Image
    ashwin_d
    Answered on July 31, 2015 at 05:10 AM

    Hello Tara2006,

    Please share the webpage URL where you have want to embed your form and we will take a look. 

    Do you want script to be written for the button which will redirect users to your JotForm? If you are not performing any other activity on the click of the button, you should just use anchor tag instead of button.

    Sample hyperlink code:

    <a target="_blank" href="YOUR_FORM_URL_GOES_HERE" class="btn btn-primary pull-left" style="float:none;text-align:center;">Explore&nbsp;<i class="fa fa-arrow-circle-right"></i></a>

     

    Sample bootstrap button with jquery script to redirect to any URL with button:

     

    <script src="~/Scripts/jquery-1.8.2.js"></script>

    <script src="~/Scripts/jquery-1.8.2.min.js"></script>

    <script type="text/javascript">

         $("#button").click(function () {

             alert("clicked");

             window.location.href = 'www.JotForm.com';

         });

    </script>

    <button type="button" class="btn btn-default" id="button">Default</button>

     

    Hope this helps.

    Do get back to us if you have any questions.

    Thank you!