The <b> tag/<strong> tag is used to make bold text, the text will become much thicker then normal text.
Where/how To Use The <b>/<strong > Tag
| Use in head or body section? | body |
| Inline or Block level tag? | Inline |
| HTML Tag Syntax? | <start tag>CONTENT</end tag> |
| XHTML Tag Syntax? | <start tag>CONTENT</end tag> |
Bold Example
| Code | Output |
|---|---|
| <b>bold text</b> | bold text |
| <strong>strong text</strong> | strong text |
Notes
- Use the strong or b tag to make your text stand out.
- Use the b tag for a pure presentational meaning and use the strong tag for giving your text more meaning to screen-readers.
- To give your text a bit less 'boldness' use the <i> or <em> tag. They render the text italic.
Common attributes for the bold tag
class, style, id, title, dir, lang
Common attributes for the strong tag
class, style, id, title, dir, lang, xml:lang
Javascript Event attributes for both bold tags
onmousedown, onmouseup, onclick, ondblclick, onmouseover, onmouseout, onmousemove, onkeydown, onkeyup, onkeypress

Comments