style - HTML CSS HTML Global Attribute

HTML CSS examples for HTML Global Attribute:style

Introduction

The style attribute adds a CSS style directly on an element.

Using the style Attribute

Demo Code

ResultView the demo in separate window

<!DOCTYPE HTML>  
<html>  
    <head>      
        <title>Example</title>  
    </head>  
    <body>  
        <a href="http://java2s.com" style="background: grey; color:white; padding:10px">java2s.com site</a>  
    </body>  
</html>  <!--from ww  w  .  j a  va 2  s  .co  m-->

Related Tutorials