Slowly Fading Rollovers between TWO Images.

i-DADA
06-08-2002, 08:33 AM
** First TIP posted by i-DADA **

Name: Rollover - Fading Style.
Class: Java Script
Level: Beginner/Intermediate.

=====================================
Code below goes in between <Body> </Body>
=====================================

### Declaring JS ###
### Blending images ###

script language=javascript>
function cnj(id,after)
{
eval(id+'.filters.blendTrans.stop();');
eval(id+'.filters.blendTrans.Apply();');
eval(id+'.src="'+after+'";');
eval(id+'.filters.blendTrans.Play();');
}
</script>

=====================================
Code Below is the inter-link between Links and
the Java Script above.
=====================================

<a href=# onfocus='this.blur()' onMouseOver='cnj("IDNumber","Image2GoesHere.gif")' onMouseOut='cnj("IDNumber","Images1GoesHere.gif")'><img id=id01 src=Image1GoesHere.gif border=0 style="filter:blendTrans(duration=0.5)" align="middle"></a>

=====================================
Above inter-link code example
=====================================

<a href=# onfocus='this.blur()' onMouseOver='cnj("id01","image2.gif")' onMouseOut='cnj("id01","image1.gif")'><img id=id01 src=image1.gif border=0 style="filter:blendTrans(duration=0.5)" align="middle"></a>

Code provided by i-DADA from http://i-dada.net (ver 3 pending).

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum