Script Categories













Graphic >>> Set Image.

Set an image on the page when the cursor is over the link. The image remains set until the user puts their cursor on another link (i.e. no onMouseOut command). Then, the image is updated to the new one.

Places I've been:

  • Toad

  • Lizard

  • Gecko

  • Step 1: Add the below code to the <body> section of your page:

    <script language="javascript" type="text/javascript">
    /* Visit http://www.yaldex.com/ for full source code
    and get more free JavaScript, CSS and DHTML scripts! */
    <!-- Begin
    var toad = new Image();
    var lizard = new Image();
    var gecko = new Image();

    toad.src = "toad.jpg";
    lizard.src = "lizard.jpg";
    gecko.src = "gecko.jpg";

    function doButtons(picimage) {
    eval("document['picture'].src = " + picimage + ".src");
    }
    //  End -->
    </script>
    <center>
    <table border=1>
    <tr><td>
    <center><h2>Places I've been:</h2></center>
    <
    p>
    <
    li><a href = "http://www.toad.com" onmouseover = "doButtons('toad')">Toad<p>

    <
    li><a href = "http://www.lizard.gov" onmouseover = "doButtons('lizard')">Lizard<p>

    <
    li><a href = "http://www.gecko.com" onmouseover = "doButtons('gecko')">Gecko<p>

    <td>
    <img name=picture src="../FSBackground/blank.gif" width=330 height=190 border=0></td>
    </tr>
    </table>
    </center>

    Step 2: The script uses 4 images as part of its interface. You can create your own, or use the 4 below (resized for easier download):

    (right click images, and select "Save Image As")
    Upload them into the same directory as your webpage.

    JavaScript Editor Get Advanced
    JavaScript and Ajax Editor,
    Validator and Debugger!

    1st JavaScript Editor.



    Code was highlighted by 1st JavaScript Editor (The Best JavaScript Editor!).
    



    ©