Casa > H > How To Make Html Invisible Text Visible

How to make HTML invisible text visible

There are few options to do this.

Use display CSS property

Just set a value of display to none so element would not be visible at all.

  1.  

  2. Some invisible text 
  3.  

Use visibility CSS property

Set the visibility value to hidden to make element invisible, but still occupy its space.

  1.  

  2. Some invisible text 
  3.  

Use opacity CSS property

You can use opacity to achieve the same effect as with visibility property by setting its value to 0.

  1.  

  2. Some invisible text 
  3.  

Use text-ident CSS property

You can achieve the same effect as in two previous techniques by setting some big negative value like -9999px for text-ident.

  1.  

  2. Some invisible text 
  3.  

Summary

Depending on what you want to achieve I recommend using only two of those techniques:

  • The one which uses display property if you don’t want an invisible element to occupy any space
  • The one which uses visibility property if you want an invisible element to occupy its space

The rest of techniques are hacky as they were not invented to do such things.

De Adlay

De que serve um wifi sem internet? :: Quando o IPL tinha dez equipas, como eram jogados os jogos?