Frequently asked questions Custom Code

How do I trigger pop-ups by a link?

How do I trigger pop-ups by a link?

Examples below require knowledge of Javascript and CSS. Tilda Customer Support does not assist in code-related questions.

Insert the following code in the T123 block from the “Other” category to the very bottom of the page (or place it in the Footer):

$(document).ready(function() {
$("body").append("<a href='" + window.location.hash + "' style='display:none'></a>");
setTimeout( function() {
$("a[href='" + window.location.hash + "']").click();

To test the code, add any block containing a pop-up, publish the page, insert the pop-up triggering link in the address bar of your browser and follow it.

Was this answer helpful?
Views: 392