The Question:
Does anyone know the code or script to delay the appearance of a CTA button? I want the button to show after they have watched the video.
This is what we're working towards:
This is the code I used (click the grey area below to copy and paste to your website)
<p style="text-align: center;">This button is set to display in 5500 miliseconds</p> <div class="container"> <div class="secretpopout"> <h2 style="text-align: center;">Ready to get started?</h2> <div class="row"> <center> <br> <a href="#block-20820" class="btn btn-hg btn-primary btn-enroll" role="button" align="center">Sign Up for $37</a> <br> </center> </div> <script> $(function() { $(".secretpopout").delay(5500).fadeIn(); }); </script> </div> </div> </div>
This is where I added it in Teachable (as an HTML Block)
Change the code below that I've put in all capital letters
<p style="text-align: center;">This button is set to display in 5500 miliseconds</p><div class="container"> <div class="secretpopout"> <h2 style="text-align: center;">Ready to get started?</h2> <div class="row"> <br> <a href="YOUR_URL_OR_BLOCK# class=" btn="" btn-hg="" btn-primary="" btn-enroll"="" role="button" align="center">Sign Up for $37_YOUR_PRICE</a> <br> </div> <script> $(function() { $(".secretpopout").delay(YOUR_MILLISECONDS).fadeIn(); });</script> </div> </div>
This resource page inspired me to create this solution:
http://stackoverflow.com/questions/2567832/code-to-make-div-appear-after-a-certain-amount-of-time