﻿jQuery.preloadImages = function() {
    for (var i = 0; i < arguments.length; i++)
        jQuery("<img>").attr("src", arguments[i]);
}


function pageLoad(sender, args) {

    // dynamically preload over images
    $(".jrollover").each(
            function() {
                jQuery("<img>").attr("src", this.src.replace(".gif", "_Over.gif"));
            }
       );

    // setup rollover actions
    $(".jrollover").hover(
            function() {
                if (this.src.search("_Over") < 0)
                    this.src = this.src.replace(".gif", "_Over.gif");
            },
            function() {
                this.src = this.src.replace("_Over", "");
            }
        );
}
