Page 1 of 1

Fire Lightbox V3 on page load.

Posted: Wed Oct 03, 2012 3:07 pm
by norman
To fire Lightbox V3 on page load, add the following code to the page. Do this after the Lightbox Setup layout.

Code: Select all

<script type="text/javascript">$(document).ready(function(){$('[rel^="lightbox"]:first').click();	});</script>
If you want this to be on one / some pages only, you could put it into a Fragment Text or Product Deescription like:

Code: Select all

!!<<script type="text/javascript">$(document).ready(function(){$('[rel^="lightbox"]:first').click();	});</script>>!!
What this does is looks for the first Lightbox link on the page and fires it's click event.