JavaScript General - How to make elements invisible?
Interview Question Database For Software Developers
|
|
| How to make elements invisible? | | How to make elements invisible? | | By: |
Change the "visibility" attribute of the style object associated with your element. Remember that a hidden element still takes up space, use "display" to make the space disappear as well.
if ( x == y) {
myElement.style.visibility = 'visible';
} else {
myElement.style.visibility = 'hidden';
}
| | ID: 2187 | Rank: 598 | Votes: 0 | Views: 204 | Submitted: 20090203 |
Copyright © 2009 FYIcenter.com
All rights in the contents of this Website are reserved by the individual author.
No part of the contents may be reproduced in any form without author's permission.
|
|
|