Lunarpages Web Hosting Forum

Author Topic: help with "mous over" image  (Read 3473 times)

Offline aant

  • Newbie
  • *
  • Posts: 5
    • http://aant.cjb.net
help with "mous over" image
« on: October 23, 2001, 07:27:00 PM »
Yo,
is eanyone know how to do folowing:
I have image A in one cel of the table and I want to, when I go over image A, in second cel of the table to appear image B.
I hope that I explane the problem?

10x for help in forward  =
aant wrote:
http://aant.cjb.net
ICQ# 7257246

stephan

  • Guest
help with "mous over" image
« Reply #1 on: October 24, 2001, 05:22:00 AM »
I know what you mean.

They have exactly this on www.mylex.com  , if you put your mouse over the buttons, the pictures change. It takes a while to load, but it does work.

I will try and get the javascript and post it here in a minute...

stephan

  • Guest
help with "mous over" image
« Reply #2 on: October 24, 2001, 05:45:00 AM »
<*html>
<head>        
<title>Page title goes here</title>  
</head>    

<body>

<TABLE border=1>

<tr><td>

<a HREF="whatever.htm" onM*ouseOver="document.pic1.src='on.gif'" onM*ouseOut="document.pic1.src='off.gif'">hello</a>

</td>

<td>

<IMG SRC="off.gif" BORDER=0 name="pic1" width="100" height="30">

</td></tr>

</table>
</body>
</html>


IMPORTANT!!! Please take out the *'s before you try to use this! It's just because this message forum won't allow html to be posted (so that people don't mess it up).

Good luck  

[ October 24, 2001: Message edited by: Stephan ]

Offline Psiphon

  • Spacescooter Operator
  • *****
  • Posts: 32
    • http://www.psiphon.net/
help with "mous over" image
« Reply #3 on: October 24, 2001, 03:16:00 PM »
Stephan, the reason it takes a while to load is because it is triggered (that is, first loaded) by an onmouseover event.  Another way to do it is to have the images preload.  That's the way I have it at my site.  Since I'm very lazy I've always used the following from Builder.com:

http://builder.cnet.com/webbuilding/0-7701-8-4561792-1.html?tag=st.bl.3880.mor   e.7701-8-4561792-1

Scroll down to where it says 'mouseover machine' (note: you'll need javascript enabled).  You input the required data and this little tool will spit out the code.

[ October 25, 2001: Message edited by: Psiphon ]

stephan

  • Guest
help with "mous over" image
« Reply #4 on: October 24, 2001, 06:24:00 PM »
Yeah, that should speed it up.

There is another way.

If you have a little introduction page (like some people do), just put all the pictures you want to preload on it, but make their sizes 0 by 0 (or 1 by 1).

I did that on my friend's webpage. http://www.mankeye.co.uk

I hope he doesn't mind me linking to it, he hasn't updated it for ages.

Offline aant

  • Newbie
  • *
  • Posts: 5
    • http://aant.cjb.net
help with "mous over" image
« Reply #5 on: October 24, 2001, 09:12:00 PM »
Yo boys tx a lot, U help me so much  
aant wrote:
http://aant.cjb.net
ICQ# 7257246