What is the use of a span tag? Give one example.


The span tag is used for following things:

  • For adding color on text
  • For adding background on text
  • Highlight any color text

Example:

<p>  
<span style="color:#ffffff;">  
In this page we use span.  
</span>  
</p>  

Leave a Reply

Your email address will not be published. Required fields are marked *