In Association with Amazon.in   Flipkart

Wednesday, June 12, 2013

CSS External Style Sheet Example

You can Link CSS Files with <link> Tag in the <head> Section as Follows:

CSS File Name: site-styles.css

<style type="text/css">
     h2 { color:#564; background-color:#EEF; }
</style>

HTML File Name: home.html

<html>
         <head>
            <title>Site Title</title>
               <link href="site-styles.css" rel="stylesheet" type="text/css" />
         </head>

        <body>
             <h2>Welcome To CSS</h2>
                <p>CSS External Styles Linking In Html File</p>
       </body
</html>

OutPut:

Welcome To CSS

CSS External Styles Linking In Html File

No comments:

Post a Comment


Related Posts Plugin for WordPress, Blogger...