Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3

Thread: Mouse Over

  1. #1
    New to the CF scene
    Join Date
    Jun 2002
    Location
    Ohio
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Unhappy Mouse Over

    I'm having real problems getting my mouse over code to work. Could someone please help me out below is a sample of the code that i'm working on..
    Only the first link is the one i'm working on now but i keep getting errors..
    I would like the rest of the links to go along the same lines as the first..

    <html>

    <head>
    <meta http-equiv="Content-Language" content="en-us">
    <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
    <meta name="GENERATOR" content="Microsoft FrontPage 4.0">
    <meta name="ProgId" content="FrontPage.Editor.Document">
    <title>Menu</title>
    <base target="main">
    <meta name="Microsoft Border" content="none, default">

    </head>

    <body background="images/greek3_copy.jpg" onload="setRollover()">

    <p>

    <A HREF="faq.html" onMouseOver="document.images['home'].src='images/home_on.gif'" onMouseOut="document.images['home'].src='images/home_off.gif'"><IMG SRC="images/home.gif" width="167" height="26" BORDER="0" NAME="home"></a></p>
    <p style="line-height: 73%"><a href="actives.htm" target="parent"><img border="0" src="images/brothers_off.gif" width="167" height="26"></a></font></p>
    <p style="line-height: 73%"><a href="social.htm" target="parent"><img border="0" src="images/calender_off.gif" width="167" height="26"></a></font></p>
    <p style="line-height: 73%"><a href="pictures.htm" target="parent"><img border="0" src="images/pictures_off.gif" width="167" height="26"></a></p>
    <p style="line-height: 73%"><a href="athletics.htm" target="parent"><img border="0" src="images/athletics_off.gif" width="167" height="26"></a></font></p>
    <p style="line-height: 73%"><a href="rush.htm" target="parent"><img border="0" src="images/rush_off.gif" width="167" height="26"></a></p>
    <p style="line-height: 73%"><a href="alumni.htm" target="parent"><img border="0" src="images/alumni_off.gif" width="167" height="26"></a></p>

    <p style="line-height: 73%"><a href="links.htm" target="parent"><img border="0" src="images/links_off.gif" width="167" height="26"></a></p>

    <p style="line-height: 73%"><a href="history.htm" target="parent"><img border="0" src="images/history_off.gif" width="167" height="26"></a></p>

    </body>

    </html>

    Thanks

  • #2
    Regular Coder
    Join Date
    Jun 2002
    Location
    FL, USA
    Posts
    734
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Okay well, i kept getting an error on this (its boldfaced)

    -------------

    <html>

    <head>
    <meta http-equiv="Content-Language" content="en-us">
    <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
    <meta name="GENERATOR" content="Microsoft FrontPage 4.0">
    <meta name="ProgId" content="FrontPage.Editor.Document">
    <title>Menu</title>
    <base target="main">
    <meta name="Microsoft Border" content="none, default">

    </head>

    <body background="images/greek3_copy.jpg" onload="setRollover()">

    <p>

    <A HREF="faq.html" onMouseOver="document.images['home'].src='images/home_on.gif'" onMouseOut="document.images['home'].src='images/home_off.gif'"><IMG SRC="images/home.gif" width="167" height="26" BORDER="0" NAME="home"></a></p>
    <p style="line-height: 73%"><a href="actives.htm" target="parent"><img border="0" src="images/brothers_off.gif" width="167" height="26"></a></font></p>
    <p style="line-height: 73%"><a href="social.htm" target="parent"><img border="0" src="images/calender_off.gif" width="167" height="26"></a></font></p>
    <p style="line-height: 73%"><a href="pictures.htm" target="parent"><img border="0" src="images/pictures_off.gif" width="167" height="26"></a></p>
    <p style="line-height: 73%"><a href="athletics.htm" target="parent"><img border="0" src="images/athletics_off.gif" width="167" height="26"></a></font></p>
    <p style="line-height: 73%"><a href="rush.htm" target="parent"><img border="0" src="images/rush_off.gif" width="167" height="26"></a></p>
    <p style="line-height: 73%"><a href="alumni.htm" target="parent"><img border="0" src="images/alumni_off.gif" width="167" height="26"></a></p>

    <p style="line-height: 73%"><a href="links.htm" target="parent"><img border="0" src="images/links_off.gif" width="167" height="26"></a></p>

    <p style="line-height: 73%"><a href="history.htm" target="parent"><img border="0" src="images/history_off.gif" width="167" height="26"></a></p>

    </body>

    </html>

    ----------------

    When i removed it, the script seemed to work fine
    CYWebmaster.com - See why we dot com!!
    ACJavascripts.com - Cut & Paste Javascripts!
    SimplyProgram.com - Personal Blog

  • #3
    Senior Coder
    Join Date
    Jun 2002
    Location
    frankfurt, german banana republic
    Posts
    1,848
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Uhm... that's easy to explain, in case you haven't noticed it yet...
    there is no javascript function called setRollover in your document. So it obviously gives an error cause it can't find that function after the page has been loaded. Or do I miss something?


  •  

    Posting Permissions

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