SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Zealot
    Join Date
    Jun 2006
    Posts
    109
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    load lightbox effects after dom is ready ?

    Hi,
    I have problem with loading lightbox image effects. I want to wait page to be loaded to apply lightbox effects on content images.

    My header code looks like this
    HTML Code:
     <script type="text/javascript" src="/index.php_files/lightbox/js/prototype.js"></script>
    
    	 <script type="text/javascript" src="/index.php_files/lightbox/js/scriptaculous.js?load=effects"></script>
    
    		<script type="text/javascript" src="/index.php_files/lightbox/js/lightbox.js"></script>		
    Now I suppose that I need to put this second line of code scriptaculous.js?load=effects in js dom is ready function.
    Can anyone share with me syntax of this code ?

    reagards

  2. #2
    It's all Geek to me silver trophybronze trophy
    ralph.m's Avatar
    Join Date
    Mar 2009
    Location
    Melbourne, AU
    Posts
    24,112
    Mentioned
    448 Post(s)
    Tagged
    8 Thread(s)
    This is not my area, but one option might be to put the scripts at the end of the page, just before the closing html tag. Many of the top javascripters recommend this these days.
    Facebook | Google+ | Twitter | Web Design Tips | Free Contact Form

    Forum Usage: Tips on posting code samples, images and more

    Forrest Gump: "IE is like a box of chocolates: you never know what you're gonna get."


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •