By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,516 Members | 1,107 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,516 IT Pros & Developers. It's quick & easy.

How do I show something I've hidden?

P: n/a
OM
I've just learnt that I can hide a picture using the following command:

document.getElementById("image0").style.display = "none";

BUT... how do I show the picture again!?

Thanks.
OM
Jul 20 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
OM
I've just found the answer...

just make it = "block"

: )

I've just learnt that I can hide a picture using the following command:

document.getElementById("image0").style.display = "none";

BUT... how do I show the picture again!?

Thanks.
OM

Jul 20 '05 #2

P: n/a
"OM" <OM@yahoo.com> writes:
I've just learnt that I can hide a picture using the following command:

document.getElementById("image0").style.display = "none";

BUT... how do I show the picture again!?


Image elements are inline elements, so to restore it, you write:

document.getElementById("image0").style.display = "inline";

If you hide a block element, e.g., a div, you would set its display to
"block" to restore it.

/L
--
Lasse Reichstein Nielsen - lr*@hotpop.com
Art D'HTML: <URL:http://www.infimum.dk/HTML/randomArtSplit.html>
'Faith without judgement merely degrades the spirit divine.'
Jul 20 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.