Preloading images and flash

Sharky Forums


Results 1 to 5 of 5

Thread: Preloading images and flash

  1. #1
    Sleeps with the Fishes
    Join Date
    Jan 2001
    Location
    Pittsburgh (please click here to donate $5 to city budget)
    Posts
    1,246

    Post Preloading images and flash

    I've got a website with a fairly large image and flash animation, does anyone know how I could preload both? Maybe with some javascript or something of the like? Thanks.

  2. #2
    Ultra Great White Shark!! richardginn's Avatar
    Join Date
    Feb 2001
    Posts
    16,118

    Post

    one thing about those animations. People hate large ones. They have to be straight and to the point.

    ------------------
    www.geocities.com/richardginn/templatehtml -Come visit the Template HTML homepage

    SBC member
    www.myeducational plan.com-come see my plan to fix the USA educational system. I hope this is sig legal. Major Site Design Update on July 18, 2006. On June 18, 2009 passed the 10,000 post mark. December 24, 2009: Major Theme change and more....

  3. #3
    Tiger Shark
    Join Date
    Mar 2001
    Location
    Next door.
    Posts
    546

    Post

    You do not need to preload the flash and images unless you have some large intro, because they will load together on your page. The one thing that people hate are large flash movies or intros. I would suggest having an entry page where the visitor has the option to enter the plain html site, a flash version of the site, or a smaller version for low bandwith users.

    preload for images (mostly used for image swaps or loading images during introductions)

    <head>
    <title>etc...
    <script language="JavaScript">
    function preload()
    {var image1=new Image()
    image1.src="the place of the first image to preload"
    //for more images, just continue the list (image2etc.)
    }
    </script>
    call the above function in an onload event <onLoad="preload()">
    preload flash (not sure if this works)

    <script language="JavaScript">
    function preload()
    {
    var flash1=new arg()
    flash1.src="where your flash is"
    }
    </script>

    hope this helps.

    ------------------
    "There are two steps to success: 1. Never tell everything you know 2. See #1"
    BLAH

  4. #4
    Sleeps with the Fishes
    Join Date
    Jan 2001
    Location
    Pittsburgh (please click here to donate $5 to city budget)
    Posts
    1,246

    Post

    My flash isn't that big...check it out www.defacetheworld.com. Milkman I currently have that javascript in there but it doesn't work...the images still show up before loaded. That script has to load the images on a pre-page, I want to preload on the actual page.

  5. #5
    Expensive Sushi
    Join Date
    Apr 2001
    Location
    JHB, South Africa
    Posts
    5

    Post

    There's an html command to make sure that the image is the first thing loaded - before all the text, I just can't remember what it is - sorry, but there is definitely one.

    use <FIG> instead of <IMG> to load the img last.

    - W.

    ------------------
    The Dedicated Computer Music Site.

    http://www.pcmusic.co.za
    The Dedicated Computer Music Site.

    http://www.pcmusic.co.za

Posting Permissions

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