In HTML, the reference CSS style has 3 ways: external style sheet, inner style sheet, inline style.This code is compiled from w3school:http://www.w3school.com.cn(1) An
At the beginning of self-learning CSS encountered problems, "linked to the external style sheet" exercise, the code is as follows:A, the CSS file code that is linked into. css-------------------------------------------------------
> > > > > Long Series One: Introducing an external CSS style sheet in HTML1 //introduce an external CSS style sheet2//Lilnk>To put inHead>the first line of the label, otherwise does not
In the HTML site can be built a CSS file, the input style, in other pages want to use this style with Cases:HTML CSS File macro control-external style sheet
Yesterday I met a colleague asking a question, @impor what is the priority of importing an external style to link to an external style, and why the result of the experiment is to determine the priority based on the position of the style
Can you use an external style sheet or an internal style sheet in this situation?
I have a menu.php, menu.php defines the navigation menu part of the left and right pages, that is, the head tag pair and body tag are in menu.php, the head tag pair uses an
' Cause I don't know what to do, but I'll take a little time.
First, let's distinguish between what is linked to an external style and the import of external styles:
We know that the two ways of referencing external styles are almost the same, that is to refer to a separate CSS
Html css style sheet layout and htmlcss style sheet Layout
I. position: fixed
Lock location (relative to the browser location), such as the pop-up window in the lower right corner of some websites.
Example:
Ii. position: absolute
1. The outer layer does not have position: a
1. style sheet Cascading Style SheetCSS Benefits:
Separation of content from performance
Web page performance is unified, easy to modify
Rich styling to make Web page layouts more flexible
Reduce the amount of Web page code, increase the browsing speed of Web pages, save network bandwidth
Use Web-independent
An external style sheet can be connected to an HTML document through the link element of HTML:
External style sheets cannot contain HTML tags such as The style element is placed in the head of the document. The required type att
the same time in a Web page introduces CSS in HTML, such as direct inserts, using a linked external style sheet, using CSS "@import" Import style sheets and use the "style" tag in i
CSS (cascading style Sheets, cascading style sheets), control the appearance of the page style, the role is to beautify the HTML page.First, the basic concept of style sheets1. Classification of Style sheets(1) Inline
same layer.
(3) link a style sheet to import a style sheet in three ways
1. In-row style sheets: It is written in the HTML Tag. The style attribute has the highest priority, but the HTML code and
the text display, to avoid this situation, it is best to join the "!--and--〉." This is the same thing as javascripts.
(7) in 〈style type= "Text/css" in the role of Type= "Text/css" is to set what type of mime, the browser is executed here to know, so that browsers do not support CSS can ignore
First, CSS style sheet classification:(i) inline style sheets: style sheets that code is written in tags control the accuracy of code reuse with the highest precedenceFormat: (b) Inline style
formatting of all pages is controlled to a CSS style sheet file. This benefits in two ways: first, simplifying the format of the Web page, the external style sheet will be saved in the browser cache, speed up the download display
Style sheet classification1, inline type. Written in the body. Precise control and poor repeatability. Body > style= "color: #90F"> better return results also Div > body>2, embedded in the head is a double mark DOCTYPE HTML Public "-//W3C//DTD XHTML 1.0 transitional//en" "http://www.w3.org/TR/xhtml1/DTD/ Xhtml1-transitional.dtd ">HTMLxmln
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.