Submit Your Article Webforumz RegistrationAnnouncements Contact Webforumz StaffContact
Home Resources Blogs Meet the Team Contact Register
 

Go Back   WebForumz.com > The Code > JavaScript

Reply
 
LinkBack Thread Tools
Old November 6th, 2007, 11:51 AM   #1
Reputable Member
 

Join Date: Sep 2007
Location: UK
Age: 43
Posts: 133
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0 jtyoungs will become famous soon enough
Fade in on load?

Was just doing some looking around, came across this site. when i clicked on the link from google in fades in to the page somehow, curious to know how it's done! great effect!

http://www.ihaveawebsite-nowwhat.co.uk/

not sure if you can see it, im using IE 6.

EDIT

it doesn't work in that link so it's the fourth down on this search

http://www.google.co.uk/search?hl=en...ff&q=seo&meta=
jtyoungs is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Old November 6th, 2007, 12:00 PM   #2
Reputable Member
 

Join Date: Jun 2007
Location: Bellevue, SK, Canada
Age: 30
Posts: 222
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0 delusion is on a distinguished road
Re: Fade in on load?

hmm.. doesn't seem to work in FireFox..

[edit] It works in IE7.. I see what you mean.. try hotscripts.com seems like Javascript..

Last edited by delusion; November 6th, 2007 at 12:04 PM..
delusion is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Old November 6th, 2007, 12:52 PM   #3
Elite Veteran
 

Join Date: Jan 2007
Location: You know where
Age: 32
Posts: 4,607
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0 karinne is a name known to all karinne is a name known to all karinne is a name known to all karinne is a name known to all karinne is a name known to all karinne is a name known to all
Re: Fade in on load?

Yeah ... those are IE only styles ... like the scrollbar thingy.

Moving to JS forum
karinne is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Old November 7th, 2007, 06:47 AM   #4
WebForumz Member
 

Join Date: Jun 2007
Location: Germany
Age: 24
Posts: 50
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0 Lucleonhart is on a distinguished road
Re: Fade in on load?

You can try some Javascript here.. *g*
Code:
<html>
<head>
<script type='text/javascript'>
var timer;
var opacity = 0;

function fadein()
{
opacity += 1;

document.body.style.opacity = opacity/10;
document.body.style.filter = 'alpha(opacity=' + opacity*10 + ')';

if(opacity == 10)
window.clearInterval(timer);

}

onload = new Function("timer = window.setInterval('fadein()',100);");

</script>
</head>
<body style='opacity:0; filter:alpha(opacity=0);'>
[BODY IN HERE]
</body>
</html>
See in action here: http://projects.lucleonhart.de/fade.html
Works in all Browser i can test (FF, IE, Opera, Safari)

Last edited by Lucleonhart; November 7th, 2007 at 06:51 AM..
Lucleonhart is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Old November 8th, 2007, 11:21 AM   #5
New Member
 

Join Date: Nov 2007
Location: Norwich, UK
Posts: 19
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0 digilover is on a distinguished road
Re: Fade in on load?

When it comes to creating visual effect, stay away from any browser dependent code and give either scriptaculous or jquery a try.

Sales folk love transitions

James.
digilover is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Old November 8th, 2007, 02:24 PM   #6
Elite Veteran
 

Join Date: Jul 2007
Location: Webforumz 24/7
Age: 17
Posts: 3,799
Blog Entries: 9
Thanks: 2
Thanked 3 Times in 3 Posts
Rep Altering Power: 0 alexgeek is a name known to all alexgeek is a name known to all alexgeek is a name known to all alexgeek is a name known to all alexgeek is a name known to all alexgeek is a name known to all
Re: Fade in on load?

That works in both IE6 and FF.
I quite like it! But I'm not sure what happens when you lots of images loading etc.
__________________
Web Design and Development Blog

Alex Perry
Technical Administrator.
alexgeek is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Old November 9th, 2007, 03:10 AM   #7
WebForumz Member
 

Join Date: Jun 2007
Location: Germany
Age: 24
Posts: 50
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Altering Power: 0 Lucleonhart is on a distinguished road
Re: Fade in on load?

That code is quite browser independent my friend.. you may add
Code:
document.body.style.KhtmlOpacity = opacity/10;
to support Konquerer and Safari.

I've added that to my startpage.. works great. (Reload page after all gfx has loaded to see the full effect ^^)
http://www.lucleonhart.de/index2.php
Lucleonhart is offline  
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Video player preview Image fade to video Lchad Flash and ActionScript 10 September 4th, 2007 11:37 AM
fade out when new movie? becccs Flash and ActionScript 2 July 28th, 2007 08:53 AM
Mutiple images fade in and out peebman2000 Flash and ActionScript 5 February 15th, 2007 03:05 PM
fade to white christopher Graphic Specifics 2 June 1st, 2006 08:02 AM
Fade Out Option in sounds not working autumn_whispers2me Flash and ActionScript 2 February 14th, 2005 05:37 PM


Search Engine Optimization by vBSEO 3.2.0 RC8