On 13 Oct 98, Gerry Ott wrote:
> Go to this site and look for the color chart a little way down the
> opening page. Move your mouse cursor over the colors and watch how
> fast it changes the page background color. This is an excellent example of
> the mouseover effect.
>
> http://www.spaceports.com/~stewson/gifs.html
>
> Comments?
Hmm... actually, the technique being used is not especially novel. It's
simply some inline Javascript that uses the onmouseover event to change
the document.bgcolor property. This has been easy to do with JS for
quite awhile.
Well, I'll show you how easy. The following code will produce the effect in
any browser that supports Javascript and colored table cells (NS 3+ and
MSIE 3+)
<!-- 'spacer.gif' hereafter is an empty transparent GIF -->
<table cellspacing=3 border=1 cellpadding=0>
<tr>
<td bgcolor="#000000">
<a href=javascript://
onmouseover="document.bgColor='black'; window.status='Black'; return
true">
<img src="spacer.gif" width="20" height="20" border=0></a></td>
<td bgcolor="#008000">
<a href=javascript://
onmouseover="document.bgColor='green'; window.status='Green'; return
true">
<img src="spacer.gif" width="20" height="20" border=0></a></td>
<td bgcolor="#2E8B57">
<a href=javascript://
onmouseover="document.bgColor='seagreen'; window.status='Seagreen';
return true">
<img src="spacer.gif" width="20" height="20" border=0></a></td>
<td bgcolor="#FF0000">
<a href=javascript://
onmouseover="document.bgColor='red'; window.status='Red'; return true">
<img src="spacer.gif" width="20" height="20" border=0></a></td>
</tr>
<tr>
<td bgcolor="#008080">
<a href=javascript://
onmouseover="document.bgColor='teal'; window.status='Teal'; return
true">
<img src="spacer.gif" width="20" height="20" border=0></a></td>
<td bgcolor="#D2B48C">
<a href=javascript://
onmouseover="document.bgColor='tan'; window.status='Tan'; return true">
<img src="spacer.gif" width="20" height="20" border=0></a></td>
<td bgcolor="#FFA500">
<a href=javascript://
onmouseover="document.bgColor='orange'; window.status='Orange';
return true">
<img src="spacer.gif" width="20" height="20" border=0></a></td>
<td bgcolor="#FFD700">
<a href=javascript://
onmouseover="document.bgColor='gold'; window.status='Gold'; return
true">
<img src="spacer.gif" width="20" height="20" border=0></a></td>
</tr>
</table>
Copy the above code, create the necessary GIF file, and within moments
you too can have a psychadelic bgcolor light show :)
-----------
Brent Eades, Almonte, Ontario
E-mail: [EMAIL PROTECTED]
[EMAIL PROTECTED]
Town of Almonte site: http://www.almonte.com/
Business site: http://www.federalweb.com
____________________________________________________________________
--------------------------------------------------------------------
Join The Web Consultants Association : Register on our web site Now
Web Consultants Web Site : http://just4u.com/webconsultants
If you lose the instructions All subscription/unsubscribing can be done
directly from our website for all our lists.
---------------------------------------------------------------------