Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

fade in page onload...

Status
Not open for further replies.

matrix07

Programmer
Mar 21, 2002
41
0
0
CA
hi there, I saw this page somewhere when the page loads, it slowly fades in to full opacity. I'm not sure if they used a bgcolor script or it's something else? Does anyone know of any script like this? Thanks in advance.


Cheers!
 
it is a meta tag
<meta http-equiv=&quot;Page-Enter&quot; content=&quot;blendtrans(duration=1.0)&quot;>

place it at the top of the page A language that doesn't affect the way you think about programming is not worth knowing.
admin@onpntwebdesigns.com
 
really, that's it? I thought there would be some javascript and css involved? I'll give it a try and see if it's what I need. Thanks for you quick response.
 
just a note: what I meant by the top of the page I meant in the <head>
<meta http-equiv=&quot;Page-Enter&quot; content=&quot;blendtrans(duration=1.0)&quot;>
</head>
section. just re-read that and it wasn't too clear A language that doesn't affect the way you think about programming is not worth knowing.
admin@onpntwebdesigns.com
 
hey, that worked well. Now say I want to do it with images. Say, I'm swapping images, would like the current image to fade out and then the next image to fade in. I probably can't use this?
 
To fade an image in you can use this.

Code:
<html>
<head>
<script>
function startTrans(){//function for fadein Image

		
		mainimage1.filters.blendTrans.Apply();
		mainimage1.style.visibility = &quot;visible&quot;;
		mainimage1.filters.blendTrans.Play()
}
</script>
</head><body onload = &quot;startTrans();&quot;>
<img src=&quot;YOUR_IMAGE.JPG&quot; width=125 height=172 alt=&quot;My Pic&quot; border=&quot;0&quot; id=&quot;mainimage1&quot; style=&quot;filter:blendTrans(duration=10); visibility:hidden;&quot;>
</body>
</html>
Hope that helps.
 
does this work in NN. I had a similar one once that I could not get to work in NN

thanks glenmac A language that doesn't affect the way you think about programming is not worth knowing.
admin@onpntwebdesigns.com
 
well, actually I don't want the fade to happen until the user actually clicks on a link. I'm trying to have like a header changer where I will be preloading images in advance. Then when the user clicks on a link, it will get the next image and so forth. I just wanted to add in a fade effect when the link is pressed, the current pic fades out and the next pic will fade in as the active header. Hope I made sense. I guess I'll be using arrays for this. Thanks.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top