How to display incorrect content using HTML5 ?
In this article, we will display the text that is not correct by using the <s> tag in the document. This tag is similar but slightly different from <del> tag. It is not used to replaced or deletes text but <del> tag is used to replaced or delete the text.
Syntax:
<s> Contents... </s>
Example 1:
<!DOCTYPE html> < html > < head > < title > How to define text that is no longer correct? </ title > < style > body { text-align: center; } .gfg { font-size: 40px; font-weight: bold; color: green; } .Beginner { font-size: 25px; font-weight: bold; } p { font-size: 20px; } </ style > </ head > < body > < div class = "gfg" > w3wiki </ div > < div class = "Beginner" > HTML5: How to define text that is no longer correct? </ div > < p > w3wiki is a < s >computer science</ s > portal for Beginner </ p > </ body > </ html > |
Output:
Example 2:
<!DOCTYPE html> < html > < head > < title > How to define text that is no longer correct </ title > </ head > < body > < p > < s > Present version of HTML is HTML 4.01. </ s > </ p > < p > Next version of HTML is HTML 5 </ p > </ body > </ html > |
Output:
Supported Browsers:
- Google Chrome
- Internet Explorer
- Firefox
- Opera
- Safari
Contact Us