intro css Flashcards
rule set and inline code
how to add style sheet
open new file with style.css but it still needs to be linked to the html code
how to link the html and css files together using the <link href=”” rel=”” attribute
You can use the <link></link> element to link HTML and CSS files together. The <link></link> element must be placed within the head of the HTML file. It is a self-closing tag and requires the following attributes:
href — like the anchor element, the value of this attribute must be the address, or path, to the CSS file. rel — this attribute describes the relationship between the HTML file and the CSS file. Because you are linking to a stylesheet, the value should be set to stylesheet.
When linking an HTML file and a CSS file together, the <link></link> element will look like the following:
<link></link>
what is a type selector
The type selector does not include the angle brackets.
Since element types are often referred to by their opening tag name, the type selector is sometimes referred to as the tag name or element selector.
p {
color: green;
}
the selector would be the p