Translate

ads

6 Jun 2019

HTML | Text Formatting

HTML | Text Formatting


HTML provides you with the power for info text similar to you be intimate in MS Word or any text redaction software system. during this article, we'd bear few such choices.

 1. Making text Bold or Strong:


       <!DOCTYPE html>
<html>
<head>
 <title>Bold</title>
</head>
<body>
 <!--Normal text-->
 <p>Hello Sayed </p>
 <!--Text in Bold-->
 <p><b>Hello Sayed</b></p>
 <!--Text in Strong-->  <p><strong>Hello Sayed</strong></p>
</body>
</html> 


Output:



2.   Making text Italic or emphasize


       <!DOCTYPE html>

<html>
<head>
 <title>Italic</title>
</head>
<body>
 <!--Normal text-->
 <p>Hello Sayed</p>
 <!--Text in Italics-->
 <p><i>Hello Sayed</i></p>
 <!--Text in Emphasize-->  <p><em>Hello Sayed</em></p>
</body>
</html> 


Output:
3.   Highlighting a text:

   <!DOCTYPE html>
<html>
<head>
 <title>Highlight</title>
</head>
<body>
 <!--Text in Normal-->
 <p>Hello Sayed</p>
 <!--Text in Highlight-->  <p><mark>Hello Sayed</mark></p>
</body>
</html> 

   

Output:


   4.Making a text Subscript or      Superscript:


<!DOCTYPE html>
<html>
<head>
 <title>Superscript and Subscript</title>
</head>
<body>
 <!--Text in Normal-->
 <p>Hello Sayed</p>
 <!--Text in Superscript-->  <p>Hello <sup>Hello Sayed</sup></p>
 <!--Text in Subcript-->  <p>Hello <sub>Hello Sayed</sub></p>
</body>
</html> 

Output:






5.   Making text smaller:



<!DOCTYPE html>
<html>
<head>
 <title>Small</title>
</head>
<body>
 <!--Text in Normal-->
 <p>Hello Sayed</p>
 <!--Text in small-->  <p><small>Hello Sayed</small></p>
</body>
</html> 


Output:

  6. Striking through the text:


<!DOCTYPE html>
<html>
<head>
 <title>Delete</title>
</head>
<body>
 <!--Text in Normal-->
 <p>Hello Sayed</p>
 <!--Text in Delete-->  <p><del>Hello Sayed</del></p>
</body>
</html>


Output:



7.  Adding a text:

<!DOCTYPE html>
<html>
<head>
 <title>Inserting</title>
</head>
<body>
 <!--Text in Normal-->
 <p>Hello Sayed</p>
 <!--Text in Insert-->  <p><ins>Hello Sayed</ins></p>
</body>
</html> 

Output:


No comments:

Post a Comment