first, the study of HTML
1, HTML (Hypertext Markup Language): Hypertext Markup Language refers to the hyper-leap TXT file, can be carried out in the inside for example: refers to the page can contain pictures, links, even music, programs and other non-text elements.
(1), why the Web page will be born, why does the HTML fire?
1, because of the development of PC, people want to show more elements to the world to see people, so the page began to slowly born.
2. The birth of C/S model people began to question this mode, because some machines are affected by the hardware, you can not enjoy the knowledge sharing services.
3, so the B/S model began to slowly birth and popularization (the demand for Web pages more and more large).
two or five big browser related
Available as for simple Understanding (41981161).
third, web standards and the understanding of the relevant
1, HTML is the structure of the Web page.
2, CSS is the manifestation of the Web page.
3, JS is the behavior of Web pages.
4, the world-level is a Web standard developed a non-profit international organization.
Iv. beginning of formal entry into HTML
(1), the form must be in <> (this angle bracket wrapped) is called the HTML tag.
< Label name > </ Label name >
(2), label classification
1, double tags (such as: HTML, body)
< HTML > < Head > </ Head > </ HTML >
<!---a label with start and end
2, single label (such as: BR, HR)
<\><\> < \ > <!-- tags only start without end, the following \ is XHTML format in H5 has been discarded can be omitted do not write -
(3)HTML Tag Relationships
1. Nested relationships or parent-child relationships
< Head > < title > </ title > </ Head >
View Code
2. Side-by-side relationship or sibling relationship
1 < Head ></ Head > 2 < Body ></ Body >
(4),Document Type <! Doctype>
1, open the editing software sublime, often can see a: the following
<! DOCTYPE HTML >
Q: What exactly is it?
A: This is the word that tells us which HTML version to use? We are using the version of HTML 5. There are many versions of HTML, so we should tell the user and the browser which version number we are using.
2, sometimes we can not see the following:
"HTTP://WWW.W3.ORG/TR/XHTML1/DTD/XHTML1-STRICT.DTD" > < xmlns= "http://www.w3.org/1999/xhtml" xml:lang= "ZH-CN">
This is the strict version in HTML.
3.
"HTTP://WWW.W3.ORG/TR/XHTML1/DTD/XHTML1-TRANSITIONAL.DTD" > < xmlns= "http://www.w3.org/1999/xhtml" xml:lang= "ZH-CN" >
This is the HTML-like transitional parsing code and so on.
(5) The Lang of the page
1.
1, the most common 2:
The en
definition language is English and the zh-CN
definition language is Chinese.
The Zh-cn property value is still used for the browser and operating system compatibility considerations
(6)the semantics of HTML tags
Vernacular: The so-called label semantics, refers to the meaning of the label.
1, why should have the semantic label
1. easy to read and maintain code
2. at the same time, the browser or web crawler can be well parsed, so as to better analyze the content of it
3. using semantic tags will provide better search engine optimization
Core: the right place to give the most reasonable label.
The semantics are good: when we get rid of CSS, the structure of the Web page is still organized and has good readability. (as good as a naked run)
Vernacular, at a glance, know that is the focus, structure is what, know what each piece of content is dry.
Follow the principle: First determine the semantic HTML, and then choose the appropriate CSS. So, we're going to learn about HTML tags and memorize them based on semantics. The implementation of any element in an HTML page depends on the HTML tag
(7), the layout label in HTML
<H1>First Level title</H1> <H2>Level Two title<P>I was a paragraph</P> </H2> <H3>Level Three title</H3> <h4>Level four title</h4> <h5>Level five title</h5> <h6>Level six title</h6>
Note: Do not use the title tag to change the font size in the same row in an HTML file only once because the H1 tag is very important! The H1 tag has the highest weight! Search engine searches when it is the first search is the contents of the H1 tag.
(8),Text decoration tags (learn)
In a Web page, you sometimes need to set the text in bold, italic, or underline, and you need to use text formatting tags in HTML to make the text appear in a special way.
Label name |
function |
Description |
<b></b> |
To display text in bold format |
Bold |
<strong></strong> |
To display text in bold format |
|
<i></i> |
Set Text to italic effect |
Italic |
<em></em> |
Set Text to italic effect |
|
<u></u> |
Add underline to Text |
Underline |
<ins></ins> |
Add underline to Text |
Insert |
<s></s> |
Add Strikethrough to Text |
Strikethrough |
<del></del> |
Add Strikethrough to Text |
|
<sup></sup> |
Superscript |
|
<sub></sub> |
Subscript |
(9)link label (emphasis)
Word abbreviation: abbreviation for anchor [??? K? (R)]. Basic explanation anchor, anchor
Creating hyperlinks in HTML is as simple as using tags to include text or pictures, with the basic syntax in the following form:
<href=target="popup Mode for target window"> Text or picture </a>
HREF: The URL address used to specify the target of the link, which has the ability to hyperlink when the href attribute is applied to the label. Hypertext Reference's abbreviation. Meaning a hypertext reference
Target: Used to specify how the linked page opens, with a value of self and blank Two, where _self is the default value and __blank is opened in a new window.
Attention:
External links need to be added HTTP// www.baidu.com
Internal links Directly link internal page names such as < a href= "index.html" > home </a >
If the link target is not determined at that time, the href attribute value of the link label is typically defined as "#" (That is, href= "#"), which means that the link is temporarily an empty link.
-
href set to Javascript:void (0)
first kind of empty link: <a href= "#" > Empty link </a
The second type of empty link: <a href = "javascript:void (0)" > empty link </a>
empty links are primarily used in conjunction with JavaScript
Not only can you create text hyperlinks, but you can add hyperlinks to various page elements, like, tables, audio, video, and more.
<href= "https://view.inews.qq.com/topic/275789"><src="mx.jpg"></ a>
(10),Anchor point Positioning (difficulty)
By creating anchor links, users can quickly navigate to the target content. There are two steps to creating an anchor link:
1. Use the corresponding ID name to label the location of the jump target. Find Anchor link ID property every label has
<h3 id= "a" > 2nd episode </h3>
?
2. Use "<a href= "#id属性值 >" link text "</a> Create link text (clicked)
< a href= "#two" > find anchor </a>
Base Tag
Grammar:
<target=/>
End: Omitted here because the length is too long (the contents of the path, character entity)
HTML summaries and some of the beginnings of CSS