0
votes

I have a page that uses fancybox to open a gallery and iframes for forms. I am wondering if I can have a hidden iframe link launch on page load while the others only open when user click on them.

1

1 Answers

2
votes

Don't use hidden iframes, I think is a bad idea (even visible iframes are a bad idea too ;)

Try this instead

jQuery(document).ready(function ($) {
    $.fancybox({
        href: "http://jsfiddle.net", 
        type: "iframe"
    });
}); // ready

Notice that the URL in the href option corresponds to what you would set in the src attribute of your iframe

JSFIDDLE