Thread: Magic Div's
View Single Post
Old 12-09-2007, 05:05 PM   #1 (permalink)
WinSrev
The Acquainted
Inquisitive 
 
WinSrev's Avatar
 
Join Date: Sep 2007
Posts: 133
Thanks: 6
WinSrev is on a distinguished road
Application Error Magic Div's

Hey,

I wanted to try and make it so that, if someone clicked a link then it'd wait 3 seconds then make a certain div disappear.

I have this code:
Code:
function hideElement(obj){
    document.getElementById(obj).style.display = "none";
}
And this on the link itself (in an on click):
Code:
window.setTimeout(hideElement(admin2), 3000);
But it just produces an error, as in it does nothing.
Any ideas?
Thanks.
Send a message via ICQ to WinSrev
WinSrev is offline  
Reply With Quote