How to use Class Attribute in HTML5

In this article I am going to explain about class attribute in HTML5.
  • 2599

Class Attribute in HTML5

Class attribute use for call to class in HTML document. Class that we use in HTML this class defined in CSS. We defined class in CSS for making more effective to Html document.

Browser that supports Class Attribute

Internet explorer, Mozilla firefox, Google chrome, opera and Safari browsers.


<ElemnetName class="class name">




    <style type="text/css">



            color: red;




            color: blue;

            font-size: 14px;





    <h1 class="class1">


    <p class="class2">

        Hello Friends</p>





Further Readings

You may also want to read these related articles: here
Ask Your Question 
Got a programming related question? You may want to post your question here


© 2020 DotNetHeaven. All rights reserved.