+ 1
Use visibility or display property of css
19th May 2021, 2:09 AM
Ayush Kumar
Ayush Kumar - avatar
+ 1
display:none means that the tag in question will not appear on the page at all (although you can still interact with it through the dom). There will be no space allocated for it between the other tags. visibility:hidden means that unlike display:none, the tag is not visible, but space is allocated for it on the page. // If you have access to google.com, try searching for this: "Which property makes a content not Visible in the webpage". you will find relevant results like: https://www.geeksforgeeks.org/what-is-the-difference-between-visibilityhidden-and-displaynone/ https://css-tricks.com/almanac/properties/v/visibility/ https://www.w3schools.com/cssref/pr_class_visibility.asp https://developer.mozilla.org/en-US/docs/Web/CSS/visibility
19th May 2021, 4:06 AM
NEZ
NEZ - avatar
0
It depends on what you wanna do If you want to remove the element and then return it, so use the display property with the none value. display: none; Then use block, inline or inline-block (according to your aim or element) to return it: display: block; display: inline-block; display: inline; If you wanna just hide the element and make it visible, so use this: visibility: hidden; Then visible for visibling: visibility: visible;
19th May 2021, 6:07 AM
Radin Masiha
Radin Masiha - avatar