HTML s element

HTML <s> tag defines the content that is no longer valid or true. For example, the price of something that has been changed.

Example

<p> You will be surprised </p>
 <p> <s> Price of piza:$18 </s> </p>
 <p> <strong> Now selling for just $10</strong> </p>
Try </>

More examples

Example

<p><s> Here the inaccurate information is written. </s></p>
 <p><s> Here the deleted text is present. </s></p>
Try </>

If a piece of content has been deleted then del element is more appropriate.

Tag omission

Both opening and closing tags are necessary for the s element.

Global Attributes

All the global attributes are applicable on the s element.

Related pages

HTML formatting introduces many other elements that format the text. For example, underline, insert, del, code etc.



Was this article helpful?

 

Email:

Message:

Get the newsletter