SlideShare a Scribd company logo
1 of 13
Introduction to CSS
CSS Defined: ,[object Object],[object Object],[object Object],[object Object],[object Object]
Three Ways to Use CSS: ,[object Object],[object Object],[object Object]
CSS Format Conflicts: ,[object Object],[object Object]
What is Meant by "Cascading"? ,[object Object],[object Object],[object Object],[object Object],[object Object],For each XHTML element, the browser will check to see which inline styles are defined, then those styles in the internal style sheet, and finally those styles in the external sheet.  For all conflicts, it will use this priority system to determine which format to display on the page. In the prior example, the paragraph would display as red, because the inline style "outranks" all the others.
Example: Inline Style <h2  style=&quot;font-family:georgia; color:red;&quot; > CAUTION: Stormy Weather! </h2> An inline style declaration like this one will affect  only that particular element .  In other words, other <h2> elements on the page will not be affected by this formatting. A semicolon must follow each style declaration. Because inline styles do not properly separate content and presentation, their use is discouraged.  We will not be using inline styles in this class. PREVIEW:
Example: Internal Style Sheet <head> <style type=&quot;text/css&quot;> h2 {font-family:georgia; color:red;} </style> </head> Styles declared in the internal style sheet will affect  all matching elements on the page .  In this example, all <h2> elements on the page will be displayed in Georgia font and in red color. For internal style sheets, all formatting declarations are placed inside the <style> element within the <head> section of the document.  An element is listed and all the styling information follows, surrounded by opening and closing curly brackets,  { } . A semicolon must still follow each style declaration.
Example: External Style Sheet <head> <link rel=&quot;stylesheet&quot; type=&quot;text/css&quot; href=&quot;style.css&quot; /> </head> Styles declared in an external style sheet will affect  all matching elements on all web pages that link to the stylesheet .  In this example, all <h2> elements on all pages using this style sheet will be displayed in Georgia font and in red color. For external style sheets, a <link> tag is placed at the beginning of the <head> section of the document specifying the external style sheet (with a .css extension) to be used for formatting.  The external style sheet uses the same syntax as the internal style sheet when listing elements and their styling. h2 {font-family:georgia; color:red;} style.css (separate file):
Internal vs. External Style Sheets ,[object Object],[object Object],[object Object],[object Object]
CSS Terminology and Syntax: ,[object Object],Correct syntax: selector {property:value;} Selector Property Value Be careful to put the semicolon after each declaration.  It is the single most common mistake made by those learning CSS.
Setting Multiple Properties: ,[object Object],[object Object],[object Object],[object Object],[object Object],Many designers choose to place the selector and the open bracket on a dedicated line and the closing bracket on its own line too.  By doing this, all the selectors in between are aligned and easy to read. You can define as many selectors as you wish for the element you are formatting. In the above example, all paragraph elements will now show red italic text that is centered on the page.
Setting a Background with CSS: body { background-image:url('picture.gif'); background-repeat:repeat-x; background-color:red; } With background-image, you can specify an image to be placed in the background of your web page. If you specify a background image, you can also decide whether the image will &quot;tile&quot; across or down the screen.  Possible values for the background-repeat property include repeat-x (horizontally only), repeat-y (vertical only), and no-repeat (no tiling at all).  If you don't specify this property at all, by default the image will repeat up and down to fill the entire page. You can use the background-color property to set one solid color for the background.  Even if you specify a background image, it is good practice to specify a color too.  If for some reason the background image is not available, the background color will be shown instead.
CSS Text Properties: The following properties can be specified for any element that contains text, such as <h1> thru <h6>, <p>, <ol>, <ul>, and <a>: Property Some Possible Values text-align:  center, left, right, justify text-decoration: underline, line-through, blink color: blue, green, yellow, red, white, etc. font-family: Arial, Verdana, &quot;Times New Roman&quot; font-size: large, 120%, 20px (pixels)    font-weight: bold, normal font-style: italic, normal For a full list of available color names, refer to the following page: http://www.w3.org/TR/css3-color/#svg-color

More Related Content

What's hot

Cascading Style Sheets - Part 01
Cascading Style Sheets - Part 01Cascading Style Sheets - Part 01
Cascading Style Sheets - Part 01Hatem Mahmoud
 
Cascading Style Sheet
Cascading Style SheetCascading Style Sheet
Cascading Style Sheetvijayta
 
How Cascading Style Sheets (CSS) Works
How Cascading Style Sheets (CSS) WorksHow Cascading Style Sheets (CSS) Works
How Cascading Style Sheets (CSS) WorksAmit Tyagi
 
Customizing the Appearance and HTML Output of Visualforce Pages
Customizing the Appearance and HTML Output of VisualforcePages Customizing the Appearance and HTML Output of VisualforcePages
Customizing the Appearance and HTML Output of Visualforce Pages Mohammed Safwat Abu Kwaik
 
Creating a webpage in html
Creating a webpage in htmlCreating a webpage in html
Creating a webpage in htmlShrey Goswami
 
Cascading style sheet
Cascading style sheetCascading style sheet
Cascading style sheetMichael Jhon
 
Introduction to Cascading Style Sheets
Introduction to Cascading Style SheetsIntroduction to Cascading Style Sheets
Introduction to Cascading Style SheetsTushar Joshi
 
How to create a html webpage using notepad
How to create a html webpage using notepadHow to create a html webpage using notepad
How to create a html webpage using notepadSophieBarwick1999
 
Css types internal, external and inline (1)
Css types internal, external and inline (1)Css types internal, external and inline (1)
Css types internal, external and inline (1)Webtech Learning
 
Chapter 4a cascade style sheet css
Chapter 4a cascade style sheet cssChapter 4a cascade style sheet css
Chapter 4a cascade style sheet cssTesfaye Yenealem
 
Basics Of Css And Some Common Mistakes
Basics Of Css And Some Common MistakesBasics Of Css And Some Common Mistakes
Basics Of Css And Some Common Mistakessanjay2211
 

What's hot (20)

Cascading Style Sheets - Part 01
Cascading Style Sheets - Part 01Cascading Style Sheets - Part 01
Cascading Style Sheets - Part 01
 
Cascading Style Sheet
Cascading Style SheetCascading Style Sheet
Cascading Style Sheet
 
Css Ppt
Css PptCss Ppt
Css Ppt
 
How Cascading Style Sheets (CSS) Works
How Cascading Style Sheets (CSS) WorksHow Cascading Style Sheets (CSS) Works
How Cascading Style Sheets (CSS) Works
 
What is CSS?
What is CSS?What is CSS?
What is CSS?
 
Css mod1
Css mod1Css mod1
Css mod1
 
Customizing the Appearance and HTML Output of Visualforce Pages
Customizing the Appearance and HTML Output of VisualforcePages Customizing the Appearance and HTML Output of VisualforcePages
Customizing the Appearance and HTML Output of Visualforce Pages
 
Creating a webpage in html
Creating a webpage in htmlCreating a webpage in html
Creating a webpage in html
 
CSS ppt
CSS pptCSS ppt
CSS ppt
 
CSS
CSSCSS
CSS
 
Cascading style sheet
Cascading style sheetCascading style sheet
Cascading style sheet
 
Css
CssCss
Css
 
Css introduction
Css  introductionCss  introduction
Css introduction
 
Introduction to Cascading Style Sheets
Introduction to Cascading Style SheetsIntroduction to Cascading Style Sheets
Introduction to Cascading Style Sheets
 
How to create a html webpage using notepad
How to create a html webpage using notepadHow to create a html webpage using notepad
How to create a html webpage using notepad
 
Css types internal, external and inline (1)
Css types internal, external and inline (1)Css types internal, external and inline (1)
Css types internal, external and inline (1)
 
Chapter 4a cascade style sheet css
Chapter 4a cascade style sheet cssChapter 4a cascade style sheet css
Chapter 4a cascade style sheet css
 
CSS - LinkedIn
CSS - LinkedInCSS - LinkedIn
CSS - LinkedIn
 
Basics Of Css And Some Common Mistakes
Basics Of Css And Some Common MistakesBasics Of Css And Some Common Mistakes
Basics Of Css And Some Common Mistakes
 
Css Basics
Css BasicsCss Basics
Css Basics
 

Viewers also liked

Špoģi-Syke
Špoģi-Syke  Špoģi-Syke
Špoģi-Syke Eva Vovka
 
7.1 xhtml validation
7.1 xhtml validation7.1 xhtml validation
7.1 xhtml validationBulldogs83
 
[Gmic]nale be cubbying
[Gmic]nale be cubbying[Gmic]nale be cubbying
[Gmic]nale be cubbyingHyoin Sung
 
Presentation 10
Presentation 10Presentation 10
Presentation 10rfvbgt111
 
6.1 special characters
6.1 special characters6.1 special characters
6.1 special charactersBulldogs83
 
Another world (1) The author Ilze
Another world (1) The author IlzeAnother world (1) The author Ilze
Another world (1) The author IlzeEva Vovka
 
Dress from newspapers_-_copy (1)
Dress from newspapers_-_copy (1)Dress from newspapers_-_copy (1)
Dress from newspapers_-_copy (1)Eva Vovka
 
Global dimension in social sciences subjects in formal
Global dimension in social sciences subjects in formalGlobal dimension in social sciences subjects in formal
Global dimension in social sciences subjects in formalEva Vovka
 
3.2 introduction to css
3.2 introduction to css3.2 introduction to css
3.2 introduction to cssBulldogs83
 
2.1 adding images
2.1 adding images2.1 adding images
2.1 adding imagesBulldogs83
 
American Campaign to supress Islam
American Campaign to supress IslamAmerican Campaign to supress Islam
American Campaign to supress IslamAbu Talha
 
Marathon Oil Corp. Industry Profile
Marathon Oil Corp. Industry ProfileMarathon Oil Corp. Industry Profile
Marathon Oil Corp. Industry ProfileLIS7205
 
Questionaire all-teachers-2011
Questionaire all-teachers-2011Questionaire all-teachers-2011
Questionaire all-teachers-2011Mihajlo Gajic
 

Viewers also liked (20)

Introduction 2 css
Introduction 2 cssIntroduction 2 css
Introduction 2 css
 
Komonvelt portoriko
Komonvelt portorikoKomonvelt portoriko
Komonvelt portoriko
 
Špoģi-Syke
Špoģi-Syke  Špoģi-Syke
Špoģi-Syke
 
7.1 xhtml validation
7.1 xhtml validation7.1 xhtml validation
7.1 xhtml validation
 
[Gmic]nale be cubbying
[Gmic]nale be cubbying[Gmic]nale be cubbying
[Gmic]nale be cubbying
 
Presentation 10
Presentation 10Presentation 10
Presentation 10
 
6.1 special characters
6.1 special characters6.1 special characters
6.1 special characters
 
Ultimate frisbee
Ultimate frisbeeUltimate frisbee
Ultimate frisbee
 
Osnove windows-a
Osnove windows-aOsnove windows-a
Osnove windows-a
 
Java ders2
Java ders2Java ders2
Java ders2
 
Another world (1) The author Ilze
Another world (1) The author IlzeAnother world (1) The author Ilze
Another world (1) The author Ilze
 
Dress from newspapers_-_copy (1)
Dress from newspapers_-_copy (1)Dress from newspapers_-_copy (1)
Dress from newspapers_-_copy (1)
 
Global dimension in social sciences subjects in formal
Global dimension in social sciences subjects in formalGlobal dimension in social sciences subjects in formal
Global dimension in social sciences subjects in formal
 
3.2 introduction to css
3.2 introduction to css3.2 introduction to css
3.2 introduction to css
 
2.1 adding images
2.1 adding images2.1 adding images
2.1 adding images
 
American Campaign to supress Islam
American Campaign to supress IslamAmerican Campaign to supress Islam
American Campaign to supress Islam
 
Marathon Oil Corp. Industry Profile
Marathon Oil Corp. Industry ProfileMarathon Oil Corp. Industry Profile
Marathon Oil Corp. Industry Profile
 
Fstpt 15-solo-english
Fstpt 15-solo-englishFstpt 15-solo-english
Fstpt 15-solo-english
 
Questionaire all-teachers-2011
Questionaire all-teachers-2011Questionaire all-teachers-2011
Questionaire all-teachers-2011
 
Geo gebra u1
Geo gebra u1Geo gebra u1
Geo gebra u1
 

Similar to 3.2 introduction to css (20)

Introduction to CSS
Introduction to CSSIntroduction to CSS
Introduction to CSS
 
TUTORIAL DE CSS 2.0
TUTORIAL DE CSS 2.0TUTORIAL DE CSS 2.0
TUTORIAL DE CSS 2.0
 
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 notes
CSS notesCSS notes
CSS notes
 
Web Programming-css.pptx
Web Programming-css.pptxWeb Programming-css.pptx
Web Programming-css.pptx
 
CSS
CSSCSS
CSS
 
Css
CssCss
Css
 
Css
CssCss
Css
 
Css 2010
Css 2010Css 2010
Css 2010
 
Css 2010
Css 2010Css 2010
Css 2010
 
Lecture-6.pptx
Lecture-6.pptxLecture-6.pptx
Lecture-6.pptx
 
Css
CssCss
Css
 
CSS
CSSCSS
CSS
 
Css.prabu
Css.prabuCss.prabu
Css.prabu
 
CSS
CSSCSS
CSS
 
html-css
html-csshtml-css
html-css
 
Css
CssCss
Css
 
CSS
CSSCSS
CSS
 
CSS Basic and Common Errors
CSS Basic and Common ErrorsCSS Basic and Common Errors
CSS Basic and Common Errors
 
CSS
CSSCSS
CSS
 

More from Bulldogs83

7.2 external style sheets
7.2 external style sheets7.2 external style sheets
7.2 external style sheetsBulldogs83
 
6.2 css link styling
6.2 css link styling6.2 css link styling
6.2 css link stylingBulldogs83
 
5.2 nesting and floating elements
5.2 nesting and floating elements5.2 nesting and floating elements
5.2 nesting and floating elementsBulldogs83
 
5.1 css box model
5.1 css box model5.1 css box model
5.1 css box modelBulldogs83
 
4.3 table styling
4.3 table styling4.3 table styling
4.3 table stylingBulldogs83
 
4.2 css classes
4.2 css classes4.2 css classes
4.2 css classesBulldogs83
 
4.1 advanced tables
4.1 advanced tables4.1 advanced tables
4.1 advanced tablesBulldogs83
 
3.1 xhtml tables
3.1 xhtml tables3.1 xhtml tables
3.1 xhtml tablesBulldogs83
 
1.4 adding comments copy (2)
1.4 adding comments   copy (2)1.4 adding comments   copy (2)
1.4 adding comments copy (2)Bulldogs83
 
1.4 adding comments copy (2)
1.4 adding comments   copy (2)1.4 adding comments   copy (2)
1.4 adding comments copy (2)Bulldogs83
 
1.3 creating links
1.3 creating links1.3 creating links
1.3 creating linksBulldogs83
 
1.3 creating links
1.3 creating links1.3 creating links
1.3 creating linksBulldogs83
 
1.2 elements and attributes copy (3)
1.2 elements and attributes   copy (3)1.2 elements and attributes   copy (3)
1.2 elements and attributes copy (3)Bulldogs83
 
1.2 elements and attributes copy (3)
1.2 elements and attributes   copy (3)1.2 elements and attributes   copy (3)
1.2 elements and attributes copy (3)Bulldogs83
 
1.1 xhtml basics
1.1 xhtml basics1.1 xhtml basics
1.1 xhtml basicsBulldogs83
 

More from Bulldogs83 (15)

7.2 external style sheets
7.2 external style sheets7.2 external style sheets
7.2 external style sheets
 
6.2 css link styling
6.2 css link styling6.2 css link styling
6.2 css link styling
 
5.2 nesting and floating elements
5.2 nesting and floating elements5.2 nesting and floating elements
5.2 nesting and floating elements
 
5.1 css box model
5.1 css box model5.1 css box model
5.1 css box model
 
4.3 table styling
4.3 table styling4.3 table styling
4.3 table styling
 
4.2 css classes
4.2 css classes4.2 css classes
4.2 css classes
 
4.1 advanced tables
4.1 advanced tables4.1 advanced tables
4.1 advanced tables
 
3.1 xhtml tables
3.1 xhtml tables3.1 xhtml tables
3.1 xhtml tables
 
1.4 adding comments copy (2)
1.4 adding comments   copy (2)1.4 adding comments   copy (2)
1.4 adding comments copy (2)
 
1.4 adding comments copy (2)
1.4 adding comments   copy (2)1.4 adding comments   copy (2)
1.4 adding comments copy (2)
 
1.3 creating links
1.3 creating links1.3 creating links
1.3 creating links
 
1.3 creating links
1.3 creating links1.3 creating links
1.3 creating links
 
1.2 elements and attributes copy (3)
1.2 elements and attributes   copy (3)1.2 elements and attributes   copy (3)
1.2 elements and attributes copy (3)
 
1.2 elements and attributes copy (3)
1.2 elements and attributes   copy (3)1.2 elements and attributes   copy (3)
1.2 elements and attributes copy (3)
 
1.1 xhtml basics
1.1 xhtml basics1.1 xhtml basics
1.1 xhtml basics
 

Recently uploaded

Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformChameera Dedduwage
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxGaneshChakor2
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesFatimaKhan178732
 
Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphThiyagu K
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfsanyamsingh5019
 
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991RKavithamani
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxmanuelaromero2013
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...Marc Dusseiller Dusjagr
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdfssuser54595a
 
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpinStudent login on Anyboli platform.helpin
Student login on Anyboli platform.helpinRaunakKeshri1
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfchloefrazer622
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfJayanti Pande
 
Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Celine George
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxiammrhaywood
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...EduSkills OECD
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docxPoojaSen20
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxpboyjonauth
 

Recently uploaded (20)

Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
A Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy ReformA Critique of the Proposed National Education Policy Reform
A Critique of the Proposed National Education Policy Reform
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and Actinides
 
Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot Graph
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
 
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptx
 
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
“Oh GOSH! Reflecting on Hackteria's Collaborative Practices in a Global Do-It...
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
 
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpinStudent login on Anyboli platform.helpin
Student login on Anyboli platform.helpin
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
Arihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdfArihant handbook biology for class 11 .pdf
Arihant handbook biology for class 11 .pdf
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
 
Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docx
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptx
 

3.2 introduction to css

  • 2.
  • 3.
  • 4.
  • 5.
  • 6. Example: Inline Style <h2 style=&quot;font-family:georgia; color:red;&quot; > CAUTION: Stormy Weather! </h2> An inline style declaration like this one will affect only that particular element . In other words, other <h2> elements on the page will not be affected by this formatting. A semicolon must follow each style declaration. Because inline styles do not properly separate content and presentation, their use is discouraged. We will not be using inline styles in this class. PREVIEW:
  • 7. Example: Internal Style Sheet <head> <style type=&quot;text/css&quot;> h2 {font-family:georgia; color:red;} </style> </head> Styles declared in the internal style sheet will affect all matching elements on the page . In this example, all <h2> elements on the page will be displayed in Georgia font and in red color. For internal style sheets, all formatting declarations are placed inside the <style> element within the <head> section of the document. An element is listed and all the styling information follows, surrounded by opening and closing curly brackets, { } . A semicolon must still follow each style declaration.
  • 8. Example: External Style Sheet <head> <link rel=&quot;stylesheet&quot; type=&quot;text/css&quot; href=&quot;style.css&quot; /> </head> Styles declared in an external style sheet will affect all matching elements on all web pages that link to the stylesheet . In this example, all <h2> elements on all pages using this style sheet will be displayed in Georgia font and in red color. For external style sheets, a <link> tag is placed at the beginning of the <head> section of the document specifying the external style sheet (with a .css extension) to be used for formatting. The external style sheet uses the same syntax as the internal style sheet when listing elements and their styling. h2 {font-family:georgia; color:red;} style.css (separate file):
  • 9.
  • 10.
  • 11.
  • 12. Setting a Background with CSS: body { background-image:url('picture.gif'); background-repeat:repeat-x; background-color:red; } With background-image, you can specify an image to be placed in the background of your web page. If you specify a background image, you can also decide whether the image will &quot;tile&quot; across or down the screen. Possible values for the background-repeat property include repeat-x (horizontally only), repeat-y (vertical only), and no-repeat (no tiling at all). If you don't specify this property at all, by default the image will repeat up and down to fill the entire page. You can use the background-color property to set one solid color for the background. Even if you specify a background image, it is good practice to specify a color too. If for some reason the background image is not available, the background color will be shown instead.
  • 13. CSS Text Properties: The following properties can be specified for any element that contains text, such as <h1> thru <h6>, <p>, <ol>, <ul>, and <a>: Property Some Possible Values text-align: center, left, right, justify text-decoration: underline, line-through, blink color: blue, green, yellow, red, white, etc. font-family: Arial, Verdana, &quot;Times New Roman&quot; font-size: large, 120%, 20px (pixels) font-weight: bold, normal font-style: italic, normal For a full list of available color names, refer to the following page: http://www.w3.org/TR/css3-color/#svg-color