CSS (Wordhole): Difference between revisions

From XPUB & Lens-Based wiki
(Created page with "==Definition== CSS (or Cascading Style Sheets) is a programming language used to change the styling (color, typography, layout, etc.etc... the limits are almost endless) of web content, by referencing HTML elements using various CSS selectors. Additionally to HTML, CSS specs are maintained my the W3C, but implementation of these specs can deffer per browser (looking at you, Internet explorer). ===Example of CSS=== <syntaxhighlight lang="CSS"> body, .bg--red, a:hover {...")
 
 
(8 intermediate revisions by 3 users not shown)
Line 1: Line 1:
==Definition==
 
CSS (or Cascading Style Sheets) is a programming language used to change the styling (color, typography, layout, etc.etc... the limits are almost endless) of web content, by referencing HTML elements using various CSS selectors. Additionally to HTML, CSS specs are maintained my the W3C, but implementation of these specs can deffer per browser (looking at you, Internet explorer).  
CSS (or Cascading Style Sheets) is a programming language used to change the styling (color, typography, layout, etc.etc... the limits are almost endless) of web content, by referencing HTML elements using various CSS selectors. Additionally to HTML, CSS specs are maintained my the W3C, but implementation of these specs can deffer per browser (looking at you, Internet explorer).  


===Example of CSS===
'''Example of CSS'''
 
<syntaxhighlight lang="CSS">
<syntaxhighlight lang="CSS">
body, .bg--red, a:hover {  
body, .bg--red, a:hover {  
Line 8: Line 9:
}
}
</syntaxhighlight>
</syntaxhighlight>
In this example, the '''selector''' selects the ''<body>'' element, and any element with the class ''bg--red'', and every link that has a pseudo class of "hover" (mouse over element). The changed '''property''' is the background-color of these elements, with a value of '''<span style="color: red;">red</span>'''.  
In this example, the '''selector''' selects the ''<body>'' element, and any element with the class ''bg--red'', and every link that has a pseudo class of "hover" (mouse over element). The changed '''property''' is the background-color of these elements, with a value of '''<span style="color: red;">red</span>'''.
 
'''Examples of websites that use CSS'''
 
* https://nu.nl
* https://worm.org
* https://startpagina.nu
 
'''Images and links'''


===Images and links===
* [https://caniuse.com CanIUse to check if your CSS property can be used in a specific browser]
* [https://caniuse.com CanIUse to check if your CSS property can be used in a specific browser]
* [https://www.w3.org/Style/CSS/current-work W3 specs for CSS]
* [https://www.w3.org/Style/CSS/current-work W3 specs for CSS]
* [https://wtf.tw/ref/duckett.pdf HTML & CSS; Design & build website by Jon Duckett]
* [https://wtf.tw/ref/duckett.pdf HTML & CSS; Design & build website by Jon Duckett]


==See also==
'''See also'''
 
[[HTML (Wordhole)]]
[[HTML (Wordhole)]]


[[Category:Wordhole]]
[[Category:Wordhole]]

Latest revision as of 10:39, 27 October 2023

CSS (or Cascading Style Sheets) is a programming language used to change the styling (color, typography, layout, etc.etc... the limits are almost endless) of web content, by referencing HTML elements using various CSS selectors. Additionally to HTML, CSS specs are maintained my the W3C, but implementation of these specs can deffer per browser (looking at you, Internet explorer).

Example of CSS

body, .bg--red, a:hover { 
    background-color: red;
}

In this example, the selector selects the <body> element, and any element with the class bg--red, and every link that has a pseudo class of "hover" (mouse over element). The changed property is the background-color of these elements, with a value of red.

Examples of websites that use CSS

Images and links

See also

HTML (Wordhole)