<A HREF=Resource Address>Link Text</A>
1. Local link
①Absolute road force:
<A HREF=C:/images/article.jpg>Absolute Road Force Link to Local Pictures</A>
②Relative Lu Jin
<A HREF =article2.jpg> Relative Lujin link to local pictures</A>
③Link to the previous directory
<A HREF=../test.htm>Link to previous directory</A>
2. URL link
Form: Protocol name://host.domain name/lujin/file name
The agreement includes:
file local system file
http WWW Server
ftp ftp server
telnet-based protocol
mailto Email
news Usenet news group
gopher GOPHER server
Wais WAIS Server
For example: <A HREF=http://www.baidu.com> Baidu</A>
3. Directory link
First set a paragraph to the link position, the format is:
<A NAME=link location name></A>
Then call the file in this link part to define the link:
<A HREF=File name#link location name>link text</A>
Of course, if you jump in a file, the file name can be omitted and not written.
2. Multi-view window FRAMESHTML files designed with FRAMES structure can divide the entire window into several independent small windows, each small window can load different files and communicate with each other.
1. Basic structure:
<HTML>
<HEAD>
<TITLE></TITLE>
</HEAD>
<FRAMESET>
<FRAME SRC=url>
<FRAME SRC=url>
...
</FRAMESET>
</HTML>
2. Size settings of each window
We divide the window into several pieces, use the ROWS attribute horizontally and use the COLS attribute vertically. The size of each piece can be achieved by the values of these two properties.
<frameset cols=#>
<frameset rows=#>
The value of # is a pair of strings enclosed in quotes. The numbers in the string represent the size occupied by each window, separated by commas in the middle. The numbers in it can also be replaced by *, indicating that the size is automatically allocated by the browser. like
<frameset cols=100,200,300>
<frameset rows=10%,20%,70%>
<frameset cols=100,*,*> Distribute windows other than 100 pixels evenly
3. Interoperability between windows
① The src attribute of frame is used to specify the content to be linked, the name attribute specifies the name of the window, and the target attribute specifies the window in which the linked file appears. Its value can be the name defined by name, or it can be the following four types of values:
<a href=url target=_blank> Shows a new window
<a href=url target=_self> displays in the same window
<a href=url target=_parent> window showing the previous file in the Frameset
<a href=url target=_top> displays throughout the browser window
②Other properties of frame
<frame frameborder=#> #=yes,no
frameborder specifies the settings of each window border: yes means there is a border, no means there is no border
<frame marginwidth=# marginheight=#>
The value of # is a pixel point. This property is used to set the width of the upper, lower, left and right boundaries of the window. If not set, it will be automatically determined by the browser.
<frame scrolling=#>#=yes,no,auto
Scrollbar settings, yes means yes means no, auto means automatically set by the browser, the default value is auto.
<frame noresize=noresize>
The noresize property specifies that the user cannot resize the frame. By default, the size of the frame can be changed by dragging the walls between the frames, which can lock the size of the frame.
3. Style sheet1. The most important function of style sheets is to provide a way to keep the styles of all web pages consistent.
The three levels of a style sheet are in order from the lower level to the higher level:
①.Built-in (inline) style sheet: suitable for content of a single element
②. Document level style sheet: suitable for the body of the entire document
③. External style sheet: can be applied in the body of multiple documents
When used, low-level stylesheets have priority on use if there is a conflict.
2. Issues that need to be paid attention to when using CSS:
① Some browsers may not support certain attribute values. At this time, the browser either ignores these attribute values or replaces them with an optional value.
② The built-in style only adapts to a single element, which actually goes against the original design intention of the style sheet, so it should be used with caution.
③ Document layer style description appears in the header of the document and is suitable for the entire body of the document. So this is how the overall style of website construction can be consistent.
④ The external style sheet is not part of the document that uses it. The external style sheet needs to be stored separately and must be explained when using it. External style sheets can be written into text files using MIME type text/css, which can be stored on any computer on the Internet, and the browser gets external style sheets as if it were a document. The <link> element at the head of the web page can also be used to specify an external style sheet. In <link>, the rel attribute is used to specify the relationship between the linked document and the document containing the modified link, and the href attribute is used to specify the URL address of the style sheet document. like
<link rel=stylesheet type=text/css href=themes/AutoTheme/style.css></link>
4. Span and divUse of <span>
In some cases, certain special font properties are required to only apply to part of the text of the entire paragraph, such as setting a word or phrase to a different font or background, etc. This allows you to use <span> elements, such as:
<p>I really like <span style=font-size:24pt;font-family:bold;color:red>programming</span>, which is a very pleasant thing. </p>
Use of <div>
In web pages, sections are a very common form, each section consists of several paragraphs. If in design, it is hoped that not only each paragraph, but also that the sections in the web page can be styled. At this time, you can use <div>, which is mainly used to specify the appearance details of a section or area in the web page.