SitePoint Sponsor

User Tag List

Results 1 to 6 of 6
  1. #1
    SitePoint Enthusiast xinete's Avatar
    Join Date
    Jan 2003
    Posts
    25
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    weird autorefresh?

    Hi,
    im making a webpage and it loads good, but, its supposed to have rollovers
    but when mouse is over a button take a little bit to load, and thats fine but then like try to reload the over_files of the other buttons and that happen in the others too... so u cant see really the effect of rollover, it works locally but no when i upload it...maybe im not explaining it well but here it is the link
    maybe u can advise me better
    http://www.hamelius.com/home1.htm


    thanks

  2. #2
    SitePoint Zealot Optimum's Avatar
    Join Date
    Apr 2003
    Location
    Miramar
    Posts
    123
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The speed of your rollovers are directly affected by your design. You have included unnecessary graphics in your buttons. The yellow area etc can be made into a background that tiles instead of a part of the button. Also the shadow of the button could be reduced a bit to allow a smaller button.

    Also if you save them as a smaller file bytes-wise this will also speed things up.

  3. #3
    SitePoint Wizard silver trophy Crazybanana's Avatar
    Join Date
    Mar 2003
    Location
    In tha fruit cellar
    Posts
    1,379
    Mentioned
    32 Post(s)
    Tagged
    1 Thread(s)
    Optimum has right, ther is too much graphics included with the buttons and personally i think the buttons are too big/heavy but its because you have the shadow effect on it. and maybe trim the filesize a bit, gfx is 115kb...
    Who's to doom when the judge himself is dragged before the bar


    Home | Web | Facebook

  4. #4
    SitePoint Enthusiast xinete's Avatar
    Join Date
    Jan 2003
    Posts
    25
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    yeah i will remake the graphics, thanks for the advise, but is it something wrong with the code, because even when all graphics are loaded in cache still downloading them again and again

    Thanks

  5. #5
    SitePoint Enthusiast
    Join Date
    Mar 2003
    Location
    PA
    Posts
    92
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm not sure it matters but why use a preload function? This is what I use and it seems to work fine...
    <SCRIPT LANGUAGE="JavaScript">
    if (document.images){
    var outImgArray = new Array()
    outImgArray["design"] = new Image(105,65)
    outImgArray["hosting"] = new Image(105,65)
    outImgArray["design"].src = "images\\designimg_out.jpg"
    outImgArray["hosting"].src = "images\\hostingimg_out.jpg"
    var inImgArray = new Array()
    inImgArray["design"] = new Image(105,65)
    inImgArray["hosting"] = new Image(105,65)
    inImgArray["design"].src = "images\\designimg_in.jpg"
    inImgArray["hosting"].src = "images\\hostingimg_in.jpg"
    }

    function imageOut(imgName){
    if (document.images){
    document.images[imgName].src = outImgArray[imgName].src
    }
    }
    function imageIn(imgName){
    if (document.images){
    document.images[imgName].src = inImgArray[imgName].src
    }
    }
    </SCRIPT>

    Notice no function to preload.

  6. #6
    SitePoint Enthusiast xinete's Avatar
    Join Date
    Jan 2003
    Posts
    25
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks i will try that


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
  •