95
rated 0 times
[
97]
[
2]
/ answers: 1 / hits: 15237
/ 12 Years ago, sat, february 25, 2012, 12:00:00
I'm not really a javascript/jquery coder, I have a very simple code to remove a div that's not working in IE
I'm using this in a Joomla page, so I call it like this:
$document->addScript(http://code.jquery.com/jquery-latest.js);//adiciona jquery
And than, in the body document:
<script>
setTimeout(function() {
$(#yourDiv).remove();
}, 50000);
</script>
FireFox and Chrome are (as always) ok. Can someone point out my mistake please? Thanks a lot :)
EDITED ************
I've tryied also with this code no jquery, but always not working in IE (9)
<script>
setTimeout('yourFunction();', 5000);
function yourFunction(){
var div = document.getElementById(yourDiv);
div.parentNode.removeChild(div);
}
</script>
More From » jquery