HTML" < style > " tag - write CSS style layout
<style> is used to set the style of HTML files. In <style> you can write CSS to typeset how the browser should render your page.
Examples of use:
<style type="text/css">
p {
color: #26b72b;
}
</style>
Above type="text/css"
may be omitted, just write:
<style>
p {
color: #26b72b;
}
</style>
If you want to directly link an external CSS stylesheet (stylesheet), use <link> .
media="print" print style
<style> has an attribute (attribute) that is media. The attribute value specifies print and can be used to restrict this style from being applied only when printing web pages:
<style media="print">
aside {
display: none;
}
</style>
HTML style attribute (inline CSS style)
In addition to using <style> or <link> tag to write CSS, all HTML tags are used can style
be specified CSS style attributes of the HTML element.
E.g:
<p style="color:red">This is a paragraph.</p>
The text of paragraph p above will turn red.
Post a Comment
0 Comments