SlideShare a Scribd company logo
1 of 12
Cascading Style sheetsCascading Style sheets
Cascading Style sheetsCascading Style sheets
 CSS stands for Cascading Style Sheets
 Styles define how to display (X)HTML elements
 Styles are normally stored in Style Sheets
 Multiple style definitions will cascade into one
 Cascading style sheets (CSS) or simply style sheets are text
files that contain one or more with in the form of
property/value pairs to determine in a Web page should be
displayed.
 They were developed with the aim to create the structure,
look and feel of a Web page but the elements present on
the web page are handled separately.
Cascading Style sheetsCascading Style sheets
CSS deals with all the style-related aspects important to
create a web page W3C (world wide web consortium)
has developed some specifications.
Two versions of CSS specification
1. CSS1
2. CSS2.
After the introduction of CSS, HTML elements that
purely deal with style related aspects, such as <u>,
<center>, and <strike> have been deprecated and W3C
has recommended that in place of this HTML element,
their replacements should be use in CSS.
 The syntax of CSS is slightly different from that HTML. In
contrast to the angle brackets (<and>), equal signs, and
quotation marks found in the HTML syntax,
 The CSS syntax contains curly braces, colons, and semicolons.
The syntax of a CSS rule is as follows:
Selector {property1: property1-value; property2: property2-
value; property3: property3-value………………..}
In the preceding syntax, selector is the element that the
rule defines, property1, property2, and property3 are the
properties (attributes) define for that element, and property1-
value, property2-value, and property3-value are values assigned
to these properties. The portion of the syntax enclosed within
the curly braces is termed as declaration.
Cascading Style sheetsCascading Style sheets
Cascading Style sheetsCascading Style sheets
Using the preceding CSS rules syntax; we can create a CSS
rule to set three background properties (background-color,
background-image, and background-repeat) for the <body>
element, as follows:
Body {background-color: #0000ff; background-image: url
(cimage1.jpg); Background-repeat: repeat-X}
 Shorthand property which enables you to set two or more
properties in one declaration has follows:
 Body {background: 0000ff url (c:image1.jpg) repeat-x}
create cascading styles in a web page in
four ways:
 Using inline styles.
 Using external styles sheets.
 Using internal style sheets
 Using style classes
Inline stylesInline styles
In the inline styles method, style for an HTML element is
specified using it’s style attribute .Inline styles are
useful when you want to define specific styles for
individual elements present on a web page.
External style sheetsExternal style sheets
An external style sheet is a separate document that
contains only CSS rules and has .css extension. External
style sheets are used to apply uniform styles to all the
web pages.
For example, let’s assume that you are creating a
website that contains more than one web page and you
want same look and feel for same types of HTML
elements in all the web pages.
In such a situation, you can first create all the required
CSS rues in an external style sheets and then link it to
all the web pages of the websites.
INTERNAL STYLE SHEETSINTERNAL STYLE SHEETS
Unlike external style sheets, internal style sheets are not
separate documents rather they are style, created inside
an HTML document.
In other words, an internal style sheet is a set of styles
that is created as a part of an HTML document.
These style sheets are useful when you want to apply
similar style to all the elements present on a web page.
Internal style sheets are created using the <style>
element that is added inside the <head> element of the
HTML document.
STYLE CLASSESSTYLE CLASSES
 In style classes method, you can create styles in the form of style classes in
external or embedded style sheets. To apply the style defined in a style class
to an HTML element, you can assign the class attribute of the HTML element
to the name of the style class. You can create two types of style classes:
universal and element specific. A universal style class starts with dot operator
(.) followed by the class name. the syntax to define a universal style class is as
follows
<style>
Class name {class definition}
</style>
 An element specific style class starts with the element name, followed by a dot
operator, which is followed by the class name. the syntax to define an element
specific style class is as follows
<style>
Element name.class name {class definition}
</style>
MULTIPLE STYLEMULTIPLE STYLE
 Multiple styles can be define by using different methods to
implement CSS. For this reason, the use of several external
style sheets result in cascading the styles, which is a
combination of styles for various HTML elements. If multiple
style affect the same element, only the last one is used. You
can link the external style sheets to the document as follows:
 <LINK rel=stylesheet type=”text/css” href=”style1.css”>
 <LINK rel=stylesheet type=”text/css” href=”style2.css”>
 <LINK rel=stylesheet type=”text/css” href=”style3.css”>
MULTIPLE STYLEMULTIPLE STYLE
 If multiple conflicting styles are found in the external style sheets, the CSS
recommendations allow users to select among several alternative style sheets
using the rel attribute of the <STYLE> tag, which is combined with the
TITLE attribute to select them by name :
<LINK rel=”alternate stylesheet” type=”text/css” href=”style1.css”
title=”style1”>
<LINK rel=”alternate stylesheet” type=”text/css” href=”style2.css”
title=”style2”>
<LINK rel=”alternate stylesheet” type=”text/css” href=”style3.css”
title=”style3”>
 
 Multiple style are included in a page by using various possible inclusion
methods. However, the style closest to the content is applied when some
conflict appears among styles

More Related Content

What's hot

Introduction to CSS
Introduction to CSSIntroduction to CSS
Introduction to CSSAmeer Khan
 
CSS Basics (Cascading Style Sheet)
CSS Basics (Cascading Style Sheet)CSS Basics (Cascading Style Sheet)
CSS Basics (Cascading Style Sheet)Ajay Khatri
 
Cascading style sheet
Cascading style sheetCascading style sheet
Cascading style sheetMichael Jhon
 
Cascading style sheets (CSS)
Cascading style sheets (CSS)Cascading style sheets (CSS)
Cascading style sheets (CSS)Harshita Yadav
 
Introduction of css
Introduction of cssIntroduction of css
Introduction of cssDinesh Kumar
 
Lesson One Fourth Quarter Fourth Year High School CSS Modern Layout and Style
Lesson One Fourth Quarter Fourth Year High School CSS Modern Layout and StyleLesson One Fourth Quarter Fourth Year High School CSS Modern Layout and Style
Lesson One Fourth Quarter Fourth Year High School CSS Modern Layout and StylePerry Mallari
 
Cascading Style Sheets (CSS) help
Cascading Style Sheets (CSS) helpCascading Style Sheets (CSS) help
Cascading Style Sheets (CSS) helpcasestudyhelp
 
Css introduction
Css introductionCss introduction
Css introductionSridhar P
 
Introduction to CSS
Introduction to CSSIntroduction to CSS
Introduction to CSSPrarthan P
 
Cascading Style Sheets
Cascading Style SheetsCascading Style Sheets
Cascading Style SheetsMarc Steel
 
Styling of css
Styling of cssStyling of css
Styling of cssJayjZens
 
Cascading Style Sheet (CSS)
Cascading Style Sheet (CSS)Cascading Style Sheet (CSS)
Cascading Style Sheet (CSS)AakankshaR
 
CSS introduction
CSS introductionCSS introduction
CSS introductionCloudTech 
 

What's hot (20)

Introduction to CSS
Introduction to CSSIntroduction to CSS
Introduction to CSS
 
introduction to CSS
introduction to CSSintroduction to CSS
introduction to CSS
 
CSS
CSS CSS
CSS
 
CSS Basics (Cascading Style Sheet)
CSS Basics (Cascading Style Sheet)CSS Basics (Cascading Style Sheet)
CSS Basics (Cascading Style Sheet)
 
Cascading style sheet
Cascading style sheetCascading style sheet
Cascading style sheet
 
Cascading style sheets (CSS)
Cascading style sheets (CSS)Cascading style sheets (CSS)
Cascading style sheets (CSS)
 
Introduction of css
Introduction of cssIntroduction of css
Introduction of css
 
Lesson One Fourth Quarter Fourth Year High School CSS Modern Layout and Style
Lesson One Fourth Quarter Fourth Year High School CSS Modern Layout and StyleLesson One Fourth Quarter Fourth Year High School CSS Modern Layout and Style
Lesson One Fourth Quarter Fourth Year High School CSS Modern Layout and Style
 
Cascading Style Sheets (CSS) help
Cascading Style Sheets (CSS) helpCascading Style Sheets (CSS) help
Cascading Style Sheets (CSS) help
 
chitra
chitrachitra
chitra
 
Css
CssCss
Css
 
Css introduction
Css introductionCss introduction
Css introduction
 
Introduction to CSS
Introduction to CSSIntroduction to CSS
Introduction to CSS
 
Cascading Style Sheets
Cascading Style SheetsCascading Style Sheets
Cascading Style Sheets
 
Styling of css
Styling of cssStyling of css
Styling of css
 
CSS - LinkedIn
CSS - LinkedInCSS - LinkedIn
CSS - LinkedIn
 
Cascading Style Sheet (CSS)
Cascading Style Sheet (CSS)Cascading Style Sheet (CSS)
Cascading Style Sheet (CSS)
 
CSS introduction
CSS introductionCSS introduction
CSS introduction
 
Introduction to css
Introduction to cssIntroduction to css
Introduction to css
 
Introduction to CSS
Introduction to CSSIntroduction to CSS
Introduction to CSS
 

Similar to Cascading style sheets

Similar to Cascading style sheets (20)

Beginners css tutorial for web designers
Beginners css tutorial for web designersBeginners css tutorial for web designers
Beginners css tutorial for web designers
 
Lecture 3CSS part 1.pptx
Lecture 3CSS part 1.pptxLecture 3CSS part 1.pptx
Lecture 3CSS part 1.pptx
 
Lecture 9 CSS part 1.pptxType Classification
Lecture 9 CSS part 1.pptxType ClassificationLecture 9 CSS part 1.pptxType Classification
Lecture 9 CSS part 1.pptxType Classification
 
Introduction to css
Introduction to cssIntroduction to css
Introduction to css
 
CSS Training in Bangalore
CSS Training in BangaloreCSS Training in Bangalore
CSS Training in Bangalore
 
Css
CssCss
Css
 
Css introduction
Css  introductionCss  introduction
Css introduction
 
Css training tutorial css3 &amp; css4 essentials
Css training tutorial css3 &amp; css4 essentialsCss training tutorial css3 &amp; css4 essentials
Css training tutorial css3 &amp; css4 essentials
 
HTML to CSS Basics Exer 2.pptx
HTML to CSS Basics Exer 2.pptxHTML to CSS Basics Exer 2.pptx
HTML to CSS Basics Exer 2.pptx
 
CSS_Day_ONE (W3schools)
CSS_Day_ONE (W3schools)CSS_Day_ONE (W3schools)
CSS_Day_ONE (W3schools)
 
lecture CSS 1-2_2022_2023.pptx
lecture CSS 1-2_2022_2023.pptxlecture CSS 1-2_2022_2023.pptx
lecture CSS 1-2_2022_2023.pptx
 
Css
CssCss
Css
 
Introduction to css
Introduction to cssIntroduction to css
Introduction to css
 
Unit 2.1
Unit 2.1Unit 2.1
Unit 2.1
 
Introduction to CSS
Introduction to CSSIntroduction to CSS
Introduction to CSS
 
Css
CssCss
Css
 
Css
CssCss
Css
 
Css siva
Css sivaCss siva
Css siva
 
Css siva
Css sivaCss siva
Css siva
 
Unit 2.1
Unit 2.1Unit 2.1
Unit 2.1
 

More from Jafar Nesargi

Network adpater,cabel,cards ,types, network devices
Network adpater,cabel,cards ,types, network devicesNetwork adpater,cabel,cards ,types, network devices
Network adpater,cabel,cards ,types, network devicesJafar Nesargi
 
An introduction to networking
An introduction to networkingAn introduction to networking
An introduction to networkingJafar Nesargi
 
Computer basics Intro
Computer basics IntroComputer basics Intro
Computer basics IntroJafar Nesargi
 
Chapter 7 relation database language
Chapter 7 relation database languageChapter 7 relation database language
Chapter 7 relation database languageJafar Nesargi
 
Chapter 6 relational data model and relational
Chapter  6  relational data model and relationalChapter  6  relational data model and relational
Chapter 6 relational data model and relationalJafar Nesargi
 
Chapter 4 record storage and primary file organization
Chapter 4 record storage and primary file organizationChapter 4 record storage and primary file organization
Chapter 4 record storage and primary file organizationJafar Nesargi
 
Introduction to-oracle
Introduction to-oracleIntroduction to-oracle
Introduction to-oracleJafar Nesargi
 
Cascading style sheets
Cascading style sheetsCascading style sheets
Cascading style sheetsJafar Nesargi
 
Session1 gateway to web page development
Session1   gateway to web page developmentSession1   gateway to web page development
Session1 gateway to web page developmentJafar Nesargi
 
Chapter 3 servlet & jsp
Chapter 3 servlet & jspChapter 3 servlet & jsp
Chapter 3 servlet & jspJafar Nesargi
 
Record storage and primary file organization
Record storage and primary file organizationRecord storage and primary file organization
Record storage and primary file organizationJafar Nesargi
 

More from Jafar Nesargi (20)

Network adpater,cabel,cards ,types, network devices
Network adpater,cabel,cards ,types, network devicesNetwork adpater,cabel,cards ,types, network devices
Network adpater,cabel,cards ,types, network devices
 
An introduction to networking
An introduction to networkingAn introduction to networking
An introduction to networking
 
Computer basics Intro
Computer basics IntroComputer basics Intro
Computer basics Intro
 
Css
CssCss
Css
 
Chapter 7 relation database language
Chapter 7 relation database languageChapter 7 relation database language
Chapter 7 relation database language
 
Chapter 6 relational data model and relational
Chapter  6  relational data model and relationalChapter  6  relational data model and relational
Chapter 6 relational data model and relational
 
Chapter 4 record storage and primary file organization
Chapter 4 record storage and primary file organizationChapter 4 record storage and primary file organization
Chapter 4 record storage and primary file organization
 
Chapter3
Chapter3Chapter3
Chapter3
 
Introduction to-oracle
Introduction to-oracleIntroduction to-oracle
Introduction to-oracle
 
Chapter2
Chapter2Chapter2
Chapter2
 
Cascading style sheets
Cascading style sheetsCascading style sheets
Cascading style sheets
 
Session1 gateway to web page development
Session1   gateway to web page developmentSession1   gateway to web page development
Session1 gateway to web page development
 
Introduction to jsp
Introduction to jspIntroduction to jsp
Introduction to jsp
 
Chapter 3 servlet & jsp
Chapter 3 servlet & jspChapter 3 servlet & jsp
Chapter 3 servlet & jsp
 
Rmi
RmiRmi
Rmi
 
Java bean
Java beanJava bean
Java bean
 
Networking
NetworkingNetworking
Networking
 
Chapter2 j2ee
Chapter2 j2eeChapter2 j2ee
Chapter2 j2ee
 
Chapter 1 swings
Chapter 1 swingsChapter 1 swings
Chapter 1 swings
 
Record storage and primary file organization
Record storage and primary file organizationRecord storage and primary file organization
Record storage and primary file organization
 

Recently uploaded

Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxthorishapillay1
 
ACC 2024 Chronicles. Cardiology. Exam.pdf
ACC 2024 Chronicles. Cardiology. Exam.pdfACC 2024 Chronicles. Cardiology. Exam.pdf
ACC 2024 Chronicles. Cardiology. Exam.pdfSpandanaRallapalli
 
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...Postal Advocate Inc.
 
Keynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designKeynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designMIPLM
 
Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Celine George
 
Judging the Relevance and worth of ideas part 2.pptx
Judging the Relevance  and worth of ideas part 2.pptxJudging the Relevance  and worth of ideas part 2.pptx
Judging the Relevance and worth of ideas part 2.pptxSherlyMaeNeri
 
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptxINTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptxHumphrey A Beña
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
What is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPWhat is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPCeline George
 
How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPCeline George
 
Transaction Management in Database Management System
Transaction Management in Database Management SystemTransaction Management in Database Management System
Transaction Management in Database Management SystemChristalin Nelson
 
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONTHEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONHumphrey A Beña
 
GRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTS
GRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTSGRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTS
GRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTSJoshuaGantuangco2
 
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Celine George
 
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdfVirtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdfErwinPantujan2
 

Recently uploaded (20)

Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptx
 
ACC 2024 Chronicles. Cardiology. Exam.pdf
ACC 2024 Chronicles. Cardiology. Exam.pdfACC 2024 Chronicles. Cardiology. Exam.pdf
ACC 2024 Chronicles. Cardiology. Exam.pdf
 
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
USPS® Forced Meter Migration - How to Know if Your Postage Meter Will Soon be...
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 
Keynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-designKeynote by Prof. Wurzer at Nordex about IP-design
Keynote by Prof. Wurzer at Nordex about IP-design
 
Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17Field Attribute Index Feature in Odoo 17
Field Attribute Index Feature in Odoo 17
 
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptxYOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
YOUVE_GOT_EMAIL_PRELIMS_EL_DORADO_2024.pptx
 
Judging the Relevance and worth of ideas part 2.pptx
Judging the Relevance  and worth of ideas part 2.pptxJudging the Relevance  and worth of ideas part 2.pptx
Judging the Relevance and worth of ideas part 2.pptx
 
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptxYOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
YOUVE GOT EMAIL_FINALS_EL_DORADO_2024.pptx
 
Raw materials used in Herbal Cosmetics.pptx
Raw materials used in Herbal Cosmetics.pptxRaw materials used in Herbal Cosmetics.pptx
Raw materials used in Herbal Cosmetics.pptx
 
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptxINTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
INTRODUCTION TO CATHOLIC CHRISTOLOGY.pptx
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
 
What is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERPWhat is Model Inheritance in Odoo 17 ERP
What is Model Inheritance in Odoo 17 ERP
 
How to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERPHow to do quick user assign in kanban in Odoo 17 ERP
How to do quick user assign in kanban in Odoo 17 ERP
 
Transaction Management in Database Management System
Transaction Management in Database Management SystemTransaction Management in Database Management System
Transaction Management in Database Management System
 
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATIONTHEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
THEORIES OF ORGANIZATION-PUBLIC ADMINISTRATION
 
GRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTS
GRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTSGRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTS
GRADE 4 - SUMMATIVE TEST QUARTER 4 ALL SUBJECTS
 
FINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptx
FINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptxFINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptx
FINALS_OF_LEFT_ON_C'N_EL_DORADO_2024.pptx
 
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 3 STEPS Using Odoo 17
 
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdfVirtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
Virtual-Orientation-on-the-Administration-of-NATG12-NATG6-and-ELLNA.pdf
 

Cascading style sheets

  • 2. Cascading Style sheetsCascading Style sheets  CSS stands for Cascading Style Sheets  Styles define how to display (X)HTML elements  Styles are normally stored in Style Sheets  Multiple style definitions will cascade into one  Cascading style sheets (CSS) or simply style sheets are text files that contain one or more with in the form of property/value pairs to determine in a Web page should be displayed.  They were developed with the aim to create the structure, look and feel of a Web page but the elements present on the web page are handled separately.
  • 3. Cascading Style sheetsCascading Style sheets CSS deals with all the style-related aspects important to create a web page W3C (world wide web consortium) has developed some specifications. Two versions of CSS specification 1. CSS1 2. CSS2. After the introduction of CSS, HTML elements that purely deal with style related aspects, such as <u>, <center>, and <strike> have been deprecated and W3C has recommended that in place of this HTML element, their replacements should be use in CSS.
  • 4.  The syntax of CSS is slightly different from that HTML. In contrast to the angle brackets (<and>), equal signs, and quotation marks found in the HTML syntax,  The CSS syntax contains curly braces, colons, and semicolons. The syntax of a CSS rule is as follows: Selector {property1: property1-value; property2: property2- value; property3: property3-value………………..} In the preceding syntax, selector is the element that the rule defines, property1, property2, and property3 are the properties (attributes) define for that element, and property1- value, property2-value, and property3-value are values assigned to these properties. The portion of the syntax enclosed within the curly braces is termed as declaration. Cascading Style sheetsCascading Style sheets
  • 5. Cascading Style sheetsCascading Style sheets Using the preceding CSS rules syntax; we can create a CSS rule to set three background properties (background-color, background-image, and background-repeat) for the <body> element, as follows: Body {background-color: #0000ff; background-image: url (cimage1.jpg); Background-repeat: repeat-X}  Shorthand property which enables you to set two or more properties in one declaration has follows:  Body {background: 0000ff url (c:image1.jpg) repeat-x}
  • 6. create cascading styles in a web page in four ways:  Using inline styles.  Using external styles sheets.  Using internal style sheets  Using style classes
  • 7. Inline stylesInline styles In the inline styles method, style for an HTML element is specified using it’s style attribute .Inline styles are useful when you want to define specific styles for individual elements present on a web page.
  • 8. External style sheetsExternal style sheets An external style sheet is a separate document that contains only CSS rules and has .css extension. External style sheets are used to apply uniform styles to all the web pages. For example, let’s assume that you are creating a website that contains more than one web page and you want same look and feel for same types of HTML elements in all the web pages. In such a situation, you can first create all the required CSS rues in an external style sheets and then link it to all the web pages of the websites.
  • 9. INTERNAL STYLE SHEETSINTERNAL STYLE SHEETS Unlike external style sheets, internal style sheets are not separate documents rather they are style, created inside an HTML document. In other words, an internal style sheet is a set of styles that is created as a part of an HTML document. These style sheets are useful when you want to apply similar style to all the elements present on a web page. Internal style sheets are created using the <style> element that is added inside the <head> element of the HTML document.
  • 10. STYLE CLASSESSTYLE CLASSES  In style classes method, you can create styles in the form of style classes in external or embedded style sheets. To apply the style defined in a style class to an HTML element, you can assign the class attribute of the HTML element to the name of the style class. You can create two types of style classes: universal and element specific. A universal style class starts with dot operator (.) followed by the class name. the syntax to define a universal style class is as follows <style> Class name {class definition} </style>  An element specific style class starts with the element name, followed by a dot operator, which is followed by the class name. the syntax to define an element specific style class is as follows <style> Element name.class name {class definition} </style>
  • 11. MULTIPLE STYLEMULTIPLE STYLE  Multiple styles can be define by using different methods to implement CSS. For this reason, the use of several external style sheets result in cascading the styles, which is a combination of styles for various HTML elements. If multiple style affect the same element, only the last one is used. You can link the external style sheets to the document as follows:  <LINK rel=stylesheet type=”text/css” href=”style1.css”>  <LINK rel=stylesheet type=”text/css” href=”style2.css”>  <LINK rel=stylesheet type=”text/css” href=”style3.css”>
  • 12. MULTIPLE STYLEMULTIPLE STYLE  If multiple conflicting styles are found in the external style sheets, the CSS recommendations allow users to select among several alternative style sheets using the rel attribute of the <STYLE> tag, which is combined with the TITLE attribute to select them by name : <LINK rel=”alternate stylesheet” type=”text/css” href=”style1.css” title=”style1”> <LINK rel=”alternate stylesheet” type=”text/css” href=”style2.css” title=”style2”> <LINK rel=”alternate stylesheet” type=”text/css” href=”style3.css” title=”style3”>    Multiple style are included in a page by using various possible inclusion methods. However, the style closest to the content is applied when some conflict appears among styles