Ron Mikhael Surara

Ron Mikhael Surara

Wednesday, October 29, 2014

What I Learned in CompSci #17: CSS

CSS

  Cascading - Multiple styles can overlap. Which style gets applied pertains to the rules of CSS cascading logic.
  Style - CSS deals with presentation and design
  Sheet - CSS is normally located on a separate file

3 Implementation:
   1. In-line - as attribute
       Example:





   2. Embedded / Internal - as style tag
       Example:
               

   3. External - as a separate file
       Example:
           


CSS Syntax:

Types of Selector:
  1. Element Selector - selects all element of a specific tag.(ex:body,p,span,...)
  2. Class Selector - selects all element of a given class.(ex:class=a, .a)
  3. ID Selector - selects all element of a given ID.(ex:id=b, #b)
  4. Pseudo Selector - selects all element with a user activated state(ex: :hover, :visited)


References:
http://moodle.pshs-brc.edu.ph/mod/resource/view.php?id=2117