SlideShare ist ein Scribd-Unternehmen logo
1 von 12
CCS
Cascading Style Sheets
What is CCS?

•   Cascading Style Sheets is a mechanism for adding style (like fonts,
    colors, spacing) to online documents.

•   It is a way to style HTML. Whereas the HTML is the content, the
    style sheet is the presentation of that document.

•   Styles were added to HTML 4.0 to solve a problem

•   External Style Sheets can save a lot of work, and they are stored in
    CCS files.
History of         CCS:
•   HTML was intended to define the content of a document, like:
    •   <h1> This is a heading </h1>
    •   <p>This is a paragraph.</p>

•   HTML was not designed to have tags to format a document.
    When tags like <font>, and color attributes were added to the
    HTML 3.2 specification, it caused many difficulties. Development
    of large web sites became a long and expensive process.

•   To solve this problem, the World Wide Web Consortium (W3C)
    created CSS.

•   In HTML 4.0, all formatting could be removed from the HTML
    document, and stored in a separate CSS file.

•   All browsers now support CSS.
Applying CCS to your
       Website
Internal
• Embedded, or internal styles are
  used for the whole page.

"
    http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd
    ">

<html>




• This will make all of the paragraphs
  in the page red and all of the links
  blue.
External
• External styles are used for
  the whole, multiple-page
  website.

• If you save a file are “web.css
  ” then it can be linked to in
  the HTML like this:

•   <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML
    1.0 Strict//EN"


"
    http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd
    ">


<html>


<head>


    <title>CSS Example</title>


    <link rel="stylesheet" type="text/css"
    href="web.css" />
CSS Selectors, Properties, and
Values
Selectors (and properties)
•   HTML has tags, CSS has 'selectors'. Selectors are the styles in
    internal and external style sheets. HTML selectors, are simply the
    names of HTML tags and are used to change the style of a
    specific tag.

•   For each selector there are 'properties' inside curly brackets,
    which simply take the form of words such as color, font-weight
    or background-color.

•   A value is given to the property following a colon (NOT an
    'equals' sign) and semi-colons separate the properties.

•   body

•   {font-size: 0.8em;

•   color: navy;}

•   This will apply the given values to the font-size and color
    properties to the body selector
Colors
     •   CSS brings 16,777,216 colours
         to your disposal. They can take
         the form of a name, an rgb
         (red/green/blue) value or a hex
         code.


     •   red
         Is the same as
         rgb(255,0,0)
         Which is the same as
         rgb(100%,0%,0%)
         Which is the same as
         #ff0000
         Which is the same as
         #f00


     •   Colours can be applied by using
         color and background-color


     •   A blue background and yellow
         text could look like this:

     •   h1 {color: yellow;

     •   background-color: blue;}
• Font Family
                           Text
 •   This is the font itself, such as Times New Roman, Arial, or Verdana.


 •   The font you specify must be on the user's computer


 •   : if the name of a font is more than one word, it should be put in quotation
     marks, such as font-family: "Times New Roman".



• Font Weight and Style

 •   This shows whether the text is bold or not. This usually works as font-weight:
     bold or font-weight: normal.


 •   Font Style states whether the text is italic or not. It can be font-style: italic or
     font-style: normal.
Video!
http://www.youtube.com/watch?v=R_FOJ
The End.
          Bibliography:
•"Cascading Style Sheets Home Page." Cascading Style Sheets. N.p.,
                         n.d. Web. 16 Oct. 2012.
          <http://www.w3.org/Style/CSS/Overview.en.html>.
   •Griffiths, Patrick. "Applying CSS." HTML and CSS Tutorials,
    References, and Articles. HTML Dog, n.d. Web. 16 Oct. 2012.
    <http://www.htmldog.com/guides/cssbeginner/applyingcss/>.
 •Griffiths, Patrick. "Colours." HTML and CSS Tutorials, References,
               and Articles. N.p., n.d. Web. 16 Oct. 2012.
       <http://www.htmldog.com/guides/cssbeginner/colours/>.
  •Griffiths, Patrick. "CSS Selectors, Properties, and Values." HTML
and CSS Tutorials, References, and Articles. HTML Dog, n.d. Web. 16
Oct. 2012. <http://www.htmldog.com/guides/cssbeginner/selectors/>.
•Griffiths, Patrick. "Text." HTML and CSS Tutorials, References, and
                 Articles. N.p., n.d. Web. 16 Oct. 2012.
         <http://www.htmldog.com/guides/cssbeginner/text/>.
•Websmarttv. "What Is CSS?" YouTube. YouTube, 27 Jan. 2010. Web.
  16 Oct. 2012. <http://www.youtube.com/watch?v=R_FOJrxb-vI>.

Weitere ähnliche Inhalte

Was ist angesagt? (20)

Css ms megha
Css ms meghaCss ms megha
Css ms megha
 
CSS
CSSCSS
CSS
 
Web topic 15 1 basic css layout
Web topic 15 1  basic css layoutWeb topic 15 1  basic css layout
Web topic 15 1 basic css layout
 
Basic-CSS-tutorial
Basic-CSS-tutorialBasic-CSS-tutorial
Basic-CSS-tutorial
 
css.ppt
css.pptcss.ppt
css.ppt
 
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)
 
Cascading style sheets
Cascading style sheetsCascading style sheets
Cascading style sheets
 
Introduction to html course digital markerters
Introduction to html course digital markertersIntroduction to html course digital markerters
Introduction to html course digital markerters
 
Web Information Systems Html and css
Web Information Systems Html and cssWeb Information Systems Html and css
Web Information Systems Html and css
 
Web Information Systems XML
Web Information Systems XMLWeb Information Systems XML
Web Information Systems XML
 
Cascading Style Sheets - CSS
Cascading Style Sheets - CSSCascading Style Sheets - CSS
Cascading Style Sheets - CSS
 
Cascading style sheets
Cascading style sheetsCascading style sheets
Cascading style sheets
 
Html
HtmlHtml
Html
 
CSS ppt
CSS pptCSS ppt
CSS ppt
 
Html and css
Html and cssHtml and css
Html and css
 
How Cascading Style Sheets (CSS) Works
How Cascading Style Sheets (CSS) WorksHow Cascading Style Sheets (CSS) Works
How Cascading Style Sheets (CSS) Works
 
Css lecture notes
Css lecture notesCss lecture notes
Css lecture notes
 
CSS Basics
CSS BasicsCSS Basics
CSS Basics
 
Cascstylesheets
CascstylesheetsCascstylesheets
Cascstylesheets
 
Unit iv xml dom
Unit iv xml domUnit iv xml dom
Unit iv xml dom
 

Andere mochten auch

機能シラバスに基づいた英語教育プログラムにおける発話自動採点システム導入可能性の検討
機能シラバスに基づいた英語教育プログラムにおける発話自動採点システム導入可能性の検討機能シラバスに基づいた英語教育プログラムにおける発話自動採点システム導入可能性の検討
機能シラバスに基づいた英語教育プログラムにおける発話自動採点システム導入可能性の検討早稲田大学
 
The Story Of Me
The Story Of MeThe Story Of Me
The Story Of MeAdam Tryon
 
Girl with a pearl earring 2
Girl with a pearl earring 2Girl with a pearl earring 2
Girl with a pearl earring 2Liisa Luhar
 
Los fenómenos del Niño y La Niña, impactos Territoriales en Bogotá D.C.
Los fenómenos del Niño y La Niña, impactos Territoriales en Bogotá D.C.  Los fenómenos del Niño y La Niña, impactos Territoriales en Bogotá D.C.
Los fenómenos del Niño y La Niña, impactos Territoriales en Bogotá D.C. Andrés Artunduaga
 
発話自動採点システムの研究と開発
発話自動採点システムの研究と開発発話自動採点システムの研究と開発
発話自動採点システムの研究と開発早稲田大学
 
Evaluation of the reliability for L2 speech rating in discourse completion te...
Evaluation of the reliability for L2 speech rating in discourse completion te...Evaluation of the reliability for L2 speech rating in discourse completion te...
Evaluation of the reliability for L2 speech rating in discourse completion te...早稲田大学
 
rpp, lks, penilaian struktur jaringan batang
rpp, lks, penilaian struktur jaringan batangrpp, lks, penilaian struktur jaringan batang
rpp, lks, penilaian struktur jaringan batangHicha Lidya
 

Andere mochten auch (13)

MODULO 4: MEMORIA HISTORICA IGNACIO MARTIN BARO
MODULO 4: MEMORIA HISTORICA IGNACIO MARTIN BAROMODULO 4: MEMORIA HISTORICA IGNACIO MARTIN BARO
MODULO 4: MEMORIA HISTORICA IGNACIO MARTIN BARO
 
Habilidades gerenciales
Habilidades gerenciales Habilidades gerenciales
Habilidades gerenciales
 
機能シラバスに基づいた英語教育プログラムにおける発話自動採点システム導入可能性の検討
機能シラバスに基づいた英語教育プログラムにおける発話自動採点システム導入可能性の検討機能シラバスに基づいた英語教育プログラムにおける発話自動採点システム導入可能性の検討
機能シラバスに基づいた英語教育プログラムにおける発話自動採点システム導入可能性の検討
 
The Story Of Me
The Story Of MeThe Story Of Me
The Story Of Me
 
Graficas calculo taller 5
Graficas  calculo taller 5Graficas  calculo taller 5
Graficas calculo taller 5
 
Girl with a pearl earring 2
Girl with a pearl earring 2Girl with a pearl earring 2
Girl with a pearl earring 2
 
Los fenómenos del Niño y La Niña, impactos Territoriales en Bogotá D.C.
Los fenómenos del Niño y La Niña, impactos Territoriales en Bogotá D.C.  Los fenómenos del Niño y La Niña, impactos Territoriales en Bogotá D.C.
Los fenómenos del Niño y La Niña, impactos Territoriales en Bogotá D.C.
 
Expresarte
ExpresarteExpresarte
Expresarte
 
発話自動採点システムの研究と開発
発話自動採点システムの研究と開発発話自動採点システムの研究と開発
発話自動採点システムの研究と開発
 
Jacet2014ykondo_final
Jacet2014ykondo_finalJacet2014ykondo_final
Jacet2014ykondo_final
 
Evaluation of the reliability for L2 speech rating in discourse completion te...
Evaluation of the reliability for L2 speech rating in discourse completion te...Evaluation of the reliability for L2 speech rating in discourse completion te...
Evaluation of the reliability for L2 speech rating in discourse completion te...
 
Basic openfoa mtutorialsguide
Basic openfoa mtutorialsguideBasic openfoa mtutorialsguide
Basic openfoa mtutorialsguide
 
rpp, lks, penilaian struktur jaringan batang
rpp, lks, penilaian struktur jaringan batangrpp, lks, penilaian struktur jaringan batang
rpp, lks, penilaian struktur jaringan batang
 

Ähnlich wie Css present

Ähnlich wie Css present (20)

Css
CssCss
Css
 
Week11 Lecture: CSS
Week11 Lecture: CSSWeek11 Lecture: CSS
Week11 Lecture: CSS
 
Cascading Style Sheet (CSS)
Cascading Style Sheet (CSS)Cascading Style Sheet (CSS)
Cascading Style Sheet (CSS)
 
BITM3730 9-19.pptx
BITM3730 9-19.pptxBITM3730 9-19.pptx
BITM3730 9-19.pptx
 
Cascading Style Sheets for web browser.pptx
Cascading Style Sheets for web browser.pptxCascading Style Sheets for web browser.pptx
Cascading Style Sheets for web browser.pptx
 
CSS
CSSCSS
CSS
 
BITM3730 9-20.pptx
BITM3730 9-20.pptxBITM3730 9-20.pptx
BITM3730 9-20.pptx
 
basic programming language AND HTML CSS JAVApdf
basic programming language AND HTML CSS JAVApdfbasic programming language AND HTML CSS JAVApdf
basic programming language AND HTML CSS JAVApdf
 
WEB TECHNOLOGY Unit-2.pptx
WEB TECHNOLOGY Unit-2.pptxWEB TECHNOLOGY Unit-2.pptx
WEB TECHNOLOGY Unit-2.pptx
 
Responsive web design with html5 and css3
Responsive web design with html5 and css3Responsive web design with html5 and css3
Responsive web design with html5 and css3
 
CSS-part-1.ppt
CSS-part-1.pptCSS-part-1.ppt
CSS-part-1.ppt
 
Css
CssCss
Css
 
Make Css easy : easy tips for css
Make Css easy : easy tips for cssMake Css easy : easy tips for css
Make Css easy : easy tips for css
 
Css tutorial
Css tutorialCss tutorial
Css tutorial
 
Intro to html, css & sass
Intro to html, css & sassIntro to html, css & sass
Intro to html, css & sass
 
Css
CssCss
Css
 
CSS
CSSCSS
CSS
 
Css
CssCss
Css
 
DHTML
DHTMLDHTML
DHTML
 
Need for css,introduction to css & basic syntax wt
Need for css,introduction to css &  basic syntax wtNeed for css,introduction to css &  basic syntax wt
Need for css,introduction to css & basic syntax wt
 

Css present

  • 2. What is CCS? • Cascading Style Sheets is a mechanism for adding style (like fonts, colors, spacing) to online documents. • It is a way to style HTML. Whereas the HTML is the content, the style sheet is the presentation of that document. • Styles were added to HTML 4.0 to solve a problem • External Style Sheets can save a lot of work, and they are stored in CCS files.
  • 3. History of CCS: • HTML was intended to define the content of a document, like: • <h1> This is a heading </h1> • <p>This is a paragraph.</p> • HTML was not designed to have tags to format a document. When tags like <font>, and color attributes were added to the HTML 3.2 specification, it caused many difficulties. Development of large web sites became a long and expensive process. • To solve this problem, the World Wide Web Consortium (W3C) created CSS. • In HTML 4.0, all formatting could be removed from the HTML document, and stored in a separate CSS file. • All browsers now support CSS.
  • 4. Applying CCS to your Website
  • 5. Internal • Embedded, or internal styles are used for the whole page. " http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd "> <html> • This will make all of the paragraphs in the page red and all of the links blue.
  • 6. External • External styles are used for the whole, multiple-page website. • If you save a file are “web.css ” then it can be linked to in the HTML like this: • <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" " http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd "> <html> <head> <title>CSS Example</title> <link rel="stylesheet" type="text/css" href="web.css" />
  • 8. Selectors (and properties) • HTML has tags, CSS has 'selectors'. Selectors are the styles in internal and external style sheets. HTML selectors, are simply the names of HTML tags and are used to change the style of a specific tag. • For each selector there are 'properties' inside curly brackets, which simply take the form of words such as color, font-weight or background-color. • A value is given to the property following a colon (NOT an 'equals' sign) and semi-colons separate the properties. • body • {font-size: 0.8em; • color: navy;} • This will apply the given values to the font-size and color properties to the body selector
  • 9. Colors • CSS brings 16,777,216 colours to your disposal. They can take the form of a name, an rgb (red/green/blue) value or a hex code. • red Is the same as rgb(255,0,0) Which is the same as rgb(100%,0%,0%) Which is the same as #ff0000 Which is the same as #f00 • Colours can be applied by using color and background-color • A blue background and yellow text could look like this: • h1 {color: yellow; • background-color: blue;}
  • 10. • Font Family Text • This is the font itself, such as Times New Roman, Arial, or Verdana. • The font you specify must be on the user's computer • : if the name of a font is more than one word, it should be put in quotation marks, such as font-family: "Times New Roman". • Font Weight and Style • This shows whether the text is bold or not. This usually works as font-weight: bold or font-weight: normal. • Font Style states whether the text is italic or not. It can be font-style: italic or font-style: normal.
  • 12. The End. Bibliography: •"Cascading Style Sheets Home Page." Cascading Style Sheets. N.p., n.d. Web. 16 Oct. 2012. <http://www.w3.org/Style/CSS/Overview.en.html>. •Griffiths, Patrick. "Applying CSS." HTML and CSS Tutorials, References, and Articles. HTML Dog, n.d. Web. 16 Oct. 2012. <http://www.htmldog.com/guides/cssbeginner/applyingcss/>. •Griffiths, Patrick. "Colours." HTML and CSS Tutorials, References, and Articles. N.p., n.d. Web. 16 Oct. 2012. <http://www.htmldog.com/guides/cssbeginner/colours/>. •Griffiths, Patrick. "CSS Selectors, Properties, and Values." HTML and CSS Tutorials, References, and Articles. HTML Dog, n.d. Web. 16 Oct. 2012. <http://www.htmldog.com/guides/cssbeginner/selectors/>. •Griffiths, Patrick. "Text." HTML and CSS Tutorials, References, and Articles. N.p., n.d. Web. 16 Oct. 2012. <http://www.htmldog.com/guides/cssbeginner/text/>. •Websmarttv. "What Is CSS?" YouTube. YouTube, 27 Jan. 2010. Web. 16 Oct. 2012. <http://www.youtube.com/watch?v=R_FOJrxb-vI>.