I load automatically on page load!
Close this FooBox to see instructions on how to do this on your site.
Loading a FooBox on Page Load
Sometimes you want to get your visitors attention right away. For that, FooBox now has a shortcode that allows you to load a FooBox when the page loads. You’ve already seen the demo, here’s how to do it:
1) Place this shortcode anywhere on your page:
2) Now, FooBox will automatically open the FIRST FooBox it finds on that page. If you want it to be a custom FooBox rather than your gallery or image or video, simply add a hidden div in the top of your content. This is the code for the auto-load on this page:
<a style="display: none;" href="#foobox-inline" target="foobox">open foobox</a> <div id="foobox-inline" style="display: none;"> <h1>Hey!</h1> <h2>I load automatically on page load!</h2> Close this FooBox to see instructions on how to do this on your site. </div>
3) Notice that in this case I also added a hidden a tag. That because I loaded inline HTML. The inline HTML method requires an a tag to trigger FooBox, so does an iFrame. But if you’re loading an image or video or gallery then you won’t need the a tag.