• Home
  • About Us
  • Contact Us
  • Privacy Policy
Powered by Blogger.

Nadian

No Another Day To Start



CSS:-CASCADING STYLED SHEETS

CSS is a language used to beautify a HTML webpage So that it can look attractive and more appealing to user. CSS is not a case sensitive language.

There are three ways to embedd CSS to HTML webpage:-

INLINE:- By using STYLE attribute in HTML elements.
INTERNAL:- By using  <style>......</style> element  in <head>......</head> section
EXTERNAL:-By using external CSS file.(* Extension for CSS file is .css *)


All the three ways of adding CSS are similar to each other and its execution is also similar
Programming language concept - PHP, CSS, XML, HTML, Javascript learning - book as laptop

let`s have a code snippet of all three types:-

All the following codes will have same output but in each code snippet we will use different method to embed CSS CODE.




Method 1:- INLINE:-

CODE:-

<html>
<head>
<title> any title </title>
</head>
<body>
<h1 style="color: blue;" >I am heading</h1>
<p style="color: red;">I am paragrah</p>
</body>
</html>



OUTPUT:-


Method 1:- INTERNAL:-

CODE:-

<html>
<head>
<title> CSS EXAMPLES </title>
<style>
h1{
color: blue;
}
p{
color: red;
}
</style>
</head>
<body>
<h1>I am heading</h1>
<p>I am paragrah</p>
</body>
</html>




OUTPUT:-




Method 1:- EXTERNAL:-


CODE:-



1.EXTERNAL CSS FILE

Silver CSS file document icon. Download css button icon isolated on blue background. CSS file symbol. Vector Illustration

h1{
color: blue;
}
p{
color: red;
}



2.HTML:-


<html>
<head>
<title> CSS EXAMPLES </title>
</head>
<body>
<h1>I am heading</h1>
<p>I am paragrah</p>
</body>
</html>

OUTPUT:-


In all the above cases CSS is embeded by using different kind of method but the output is similar in case of all types it doesn`t matter what kind of method we are using, output always remain same.
CSS also have concept of classes which are useful when we need to apply similar kind of  properties
to multiple elements.


Share
Tweet
Pin
Share
No comments
Newer Posts
Older Posts

About me

About Me

We are a group of Computer Science Engineers & Students. We are working together to help you in learning new things to build your skills.

Follow Us

  • facebook
  • twitter
  • instagram
  • linkedin

recent posts

Facebook

Blog Archive

  • July 2019 (1)
  • June 2019 (3)
  • May 2019 (1)
  • April 2019 (3)
  • March 2019 (3)
  • February 2019 (2)
  • January 2019 (2)
  • March 2011 (1)
  • May 1999 (1)

Created with by ThemeXpose | Distributed by Blogger Templates

About

nadian.in NO ANOTHER DAY TO START
We are a group of Computer Science Engineers and Students. We are working together to help you in learning new things to build your skills..

Quick Links
  • About Us
  • Contact Us
  • Privacy Policy

Copyright ; 2018 All Rights Reserved by Nadian.in.