Formatting tags in the HTML | Formatting
HTML ਫਾਰਮੈਟਿੰਗ (Formatting) ਵੈੱਬ ਪੇਜਾਂ ਦੀ ਬਿਹਤਰ ਦਿੱਖ ਲਈ ਟੈਕਸਟ ਨੂੰ ਫਾਰਮੇਟ ਕਰਨ ਦੀ ਇੱਕ ਪ੍ਰਕਿਰਿਆ ਹੈ। HTML ਸਾਨੂੰ CSS (ਕਾਸਕੇਡਿੰਗ ਸਟਾਈਲ ਸ਼ੀਟਸ) ਦੀ ਵਰਤੋਂ ਕੀਤੇ ਬਿਨਾਂ ਵੀ ਟੈਕਸਟ ਨੂੰ ਫਾਰਮੈਟ ਕਰਨ ਦੀ ਯੋਗਤਾ ਪ੍ਰਦਾਨ ਕਰਦਾ ਹੈ। HTML ਵਿੱਚ ਬਹੁਤ ਸਾਰੇ ਟੈਗਜ਼ ਅਤੇ ਐਟਰੀਬਿਊਟਸ ਮੌਜੂਦ ਹਨ ਜੋ ਵੈੱਬਪੇਜ਼ ਦੇ ਕੰਟੈਂਟਸ ਫਾਰਮੇਟ ਕਰਨ ਵਿੱਚ ਸਾਡੀ ਸਹਾਇਤਾ ਕਰਦੇ ਹਨ। HTML ਵਿੱਚ ਵਾਰਮੈਟਿੰਗ ਲਈ ਆਮ ਤੌਰ ਤੇ ਵਰਤ ਜਾਣ ਵਾਲੇ ਟੈਗਜ਼ ਅਤੇ ਐਂਟਰੀਬਿਊਟਸ ਦਾ ਵਰਣਨ ਹੇਠਾਂ ਕੀਤਾ ਗਿਆ ਹੈ :
Bold, ਇਟੈਲਿਕ, ਅੰਡਰਲਾਈਨ ਅਤੇ ਸਟ੍ਰਾਈਕਰੋ (Bold, Italic, Underline und Strikethrough) :
HTML ਸਾਨੂੰ ਟੈਕਸਟ ਉੱਪਰ ਉਸੇ ਤਰ੍ਹਾਂ ਦੀ ਫਾਰਮੇਟਿੰਗ ਲਾਗੂ ਕਰਨ ਦੀ ਯੋਗਤਾ ਪ੍ਰਦਾਨ ਕਰਦਾ ਹੈ ਜਿਵੇਂ ਅਸੀਂ MS Word ਜਾਂ ਕਿਸੇ ਵੀ ਹੋਰ ਟੈਕਸਟ ਐਡੀਟਿੰਗ ਸਾਫਟਵੇਅਰ ਵਿੱਚ ਕਰਦੇ ਹਾਂ।ਹੇਠਾ ਦਿੱਤੇ ਟੰਗਜ਼ ਦੀ ਵਰਤੋਂ ਨਾਲ ਟੈਕਸਟ ਉੱਪਰ ਸਾਧਾਰਣ ਫਾਰਮੇਟਿੰਗ ਇਫੈਕਟਸ ਲਾਗੂ ਕੀਤੇ ਜਾ ਸਕਦੇ ਹਨ:
HTML contains several elements for defining text with a special meaning.
This text is bold
This text is italic
This is subscript and superscript
Formatting elements were designed to display special types of text:
<b>
- Bold text<strong>
- Important text<i>
- Italic text<em>
- Emphasized text<mark>
- Marked text<small>
- Smaller text<del>
- Deleted text<ins>
- Inserted text<sub>
- Subscript text<sup>
- Superscript text<s>
- Strikethrough textThe HTML <b>
element defines bold text, without any extra importance.
<!DOCTYPE html>
<html>
<head>
<title>Formatting Tags</title>
</head>
<body>
<h1>Formatting Tags in the HTML</h1>
<HR>
<b> - Bold text</b><BR>
<strong> - Important text</strong><BR>
<i> - Italic text</i><BR>
<em> - Emphasized text</em><BR>
<mark> - Marked text</mark><BR>
<small> - Smaller text</small><BR>
<del> - Deleted text</del><BR>
<ins> - Inserted text</ins><BR>
<s> - Strikethrough</s>
5 <sub> 2</sub> - Subscript text<BR>
5 <sup> 2</sup> - Superscript text<BR>
</body>
</html>
Tag | Description |
---|---|
<b> | Defines bold text |
<em> | Defines emphasized text |
<i> | Defines a part of text in an alternate voice or mood |
<small> | Defines smaller text |
<strong> | Defines important text |
<sub> | Defines subscripted text |
<sup> | Defines superscripted text |
<ins> | Defines inserted text |
<del> | Defines deleted text |
<mark> | Defines marked/highlighted text |