The <strong> tag in HTML is the parse tag and used to show the importance of text.
Syntax:
<strong> Contents... </strong>
Example:
<!DOCTYPE html> < html > < head > < title >strong Tag</ title > < style > body { text-align:center; } h1 { color:green; } </ style > </ head > < body > < h1 >GeeksforGeeks</ h1 > < h2 >< strong > Tag</ h2 > < strong >Welcome to geeksforGeeks!</ strong > </ body > </ html > |
Output:
Example 2: Use CSS property to set bold font weight.
<!DOCTYPE html> < html > < head > < title >strong Tag</ title > < style > body { text-align:center; } h1 { color:green; } .gfg { font-weight:bold; } </ style > </ head > < body > < h1 >GeeksforGeeks</ h1 > < h2 >font-weight: bold;</ h2 > < div class = "gfg" >Welcome to geeksforGeeks!</ div > </ body > </ html > |
Output:
Supported Browser: The browser supported by <strong> tag are listed below:
- Google Chrome
- Safari
- Internet Explorer
- Firefox
- Opera
leave a comment
0 Comments