Javascript HELP!!!
Javascript HELP!!!
Out of context: Reply #3
- Started
- Last post
- 25 Responses
- acescence0
yeah, i'd use jquery. otherwise, you need to first set the opacity to 0:
var element = document.getElementById( 'fadeBlock' );
element.style.opacity = 0;
element.style.filter = 'alpha(opacity = 0)';but that has to be executed after the element actually loads,so the js has to go after fadeBlock in the document, not in head, or you have to trigger it onload or you'll get an error.
just use jquery.