visibility vs display

  • Thread starter Michael Laplante
  • Start date
M

Michael Laplante

visibility:hidden versus display:none.

What are the differences and when would you use one over the other?

M
 
H

Hywel Jenkins

Michael said:
visibility:hidden versus display:none.

What are the differences and when would you use one over the other?

Try them and see. "visibility" simply hides content, "display" also
removes it from the flow.
 
I

ironcorona

Michael said:
visibility:hidden versus display:none.

What are the differences and when would you use one over the other?

visibility:hidden means that the element is still there and taking up
space on the screen but just can't be seen. (the space taken up by the
content is just a white box).

display:none means that the content is taken out of the flow of the page
altogether. (it may as well not be there in the first place).

As to when you would use one over the other:
When ever you consider appropriate I guess
:)
 
A

Andy Dingley

Michael said:
visibility:hidden versus display:none.

What are the differences and when would you use one over the other?

It's the difference between [visibility] painting one out (but it still
leaving a hole behind) and [display] vanishing altogether as if it had
never been there, with the other elements flowing around into its
space.

Generally use display:none;

If you want to make a "menu button" vanish, but without disturbing the
rest of a toolbar, then use visibility.
 
D

dorayme

ironcorona said:
display:none means that the content is taken out of the flow of the page
altogether. (it may as well not be there in the first place).

Experienced folk can still feel its presence (or absence?)...
 
I

ironcorona

dorayme said:
Experienced folk can still feel its presence (or absence?)...

Like the way one can feel the presence of the previous occupant when one
goes to the toilet and the seat's warm.
:)
 
D

dorayme

ironcorona said:
Like the way one can feel the presence of the previous occupant when one
goes to the toilet and the seat's warm.
:)

No, it is more like knowing something has changed but not knowing
quite what when one walks into a room where the clock stopped
ticking a while back...
 
I

ironcorona

dorayme said:
No, it is more like knowing something has changed but not knowing
quite what when one walks into a room where the clock stopped
ticking a while back...

Similar in many ways to the inference that Santa has been, when one
finds cookie crumbs and an glass of milk under the tree.
 
D

dorayme

ironcorona said:
Similar in many ways to the inference that Santa has been, when one
finds cookie crumbs and an glass of milk under the tree.

Again, no. Your cases are of actual physical things. It is the
absence of them that is important.
 
I

ironcorona

dorayme said:
Again, no. Your cases are of actual physical things. It is the
absence of them that is important.

Oh I see what you're getting at. Though I'm not entirely sure that
Santa counts as an actual physical thing :)
 
D

dorayme

ironcorona said:
dorayme wrote:

Oh I see what you're getting at. Though I'm not entirely sure that
Santa counts as an actual physical thing :)

<g> ... but breadcrumbs and glasses and milk are, no?
 
I

ironcorona

Knowing that last night you said something stupid to someone but not
remembering what due to one to many Long Island Ice Teas?
 
M

Mark Parnell

Deciding to do something for the good of humanity, dorayme
Again, no. Your cases are of actual physical things. It is the
absence of them that is important.

OK, so it's the absence of the cookies and milk that you left there the
night before that tells you Santa has been.

Of course, you could blame your cat.
 
I

ironcorona

Mark said:
Deciding to do something for the good of humanity, dorayme


OK, so it's the absence of the cookies and milk that you left there the
night before that tells you Santa has been.

Of course, you could blame your cat.

Except your cat's been missing for the last six months. So perhaps it's
the absence of your cat that tells you Santa has been.
 
D

dorayme

ironcorona said:
Except your cat's been missing for the last six months. So perhaps it's
the absence of your cat that tells you Santa has been.

Please! If you are going to do nonsense, you must be sensible
about it. We are talking noticing things on the spot, short term.
Throwing in a 6 month gap is unacceptable babbling.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,579
Members
45,053
Latest member
BrodieSola

Latest Threads

Top