


The
tag is mainly used in image maps. Through this tag, the active area (also known as hotspot) can be set in the image map, so that when the user moves the mouse to the specified active area and clicks, it will automatically link Go to the preset page. Its basic syntax structure is as follows:
class and id: specify hot spots respectively. The type and id number.
alt: Alternative text used to set hotspots.
href: used to set the url address linked to the hotspot.
shape and coords: are the two main parameters used to set the shape and size of the hotspot. Its basic usage is as follows:
means setting the shape of the hotspot to a rectangle, and the coordinates of the upper left corner vertex are (X1 , y1), the coordinates of the lower right corner vertex are (X2, y2).
means setting the shape of the hotspot to be a circle, the center coordinates of the circle are (X1, y1), and the radius is r.
indicates that the shape of the hotspot is set to a polygon, and the coordinates of each vertex are ( X1,y1), (X2,y2), (x3,y3)….
Remarks: The positions of x1, y1, x2, y2 are determined based on the picture, not the size of the window.
mark divides the area of action in the image map, so the area of action it divides must be within the area of the image map, so before using the mark to divide the area, HTML must be used Another tag
属性 | 值 | 描述 | DTD |
---|---|---|---|
alt | 文本 | 为一个区域指定备选文本 | STF |
Optional attributes
property | value | Description | DTD | ||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
coords | Coordinates | Specify the coordinates of an area | STF | ||||||||||||||||||||||||
href | URL | Specify the link target of a region | STF | ||||||||||||||||||||||||
nohref | nohref | Indicates that there is no corresponding link in the area | STF | ||||||||||||||||||||||||
shape | default
|
Specify the shape of the area | STF | ||||||||||||||||||||||||
target | _blank_parent_self_top | Indicate where to open the new page | TF |
Core Attributes
Thetag supports the following core attributes:
属性 | 值 | 描述 | DTD |
---|---|---|---|
accesskey | 字符 | 设置访问元素的键盘快捷键 | STF |
class | 类名 | 指明元素的类名 | STF |
dir | rtl ltr |
指定元素里内容的文本方向 | STF |
id | id | 指明元素的唯一id | STF |
lang | 语言代码 | 指定元素内容的语言代码 | STF |
style | 样式定义 | 指定元素的内嵌样式 | STF |
tabindex | 数字 | 指定元素的Tab键顺序 | STF |
title | 文本 | 指定元素的提示文本 | STF |
xml:lang | 语言代码 | 在XHTML文档中指定元素内容的语言代码 | STF |
More information about core properties.
Event Properties
Thetag supports the following event attributes:
属性 | 值 | 描述 | DTD |
---|---|---|---|
onblur | 脚本 | 当元素失去焦点时执行脚本 | STF |
onclick | 脚本 | 在元素区域内单击鼠标(不区分左右键)时执行脚本 | STF |
ondblclick | 脚本 | 在元素区域内双击鼠标(不区分左右键)时执行脚本 | STF |
onfocus | 脚本 | 当元素取得焦点时执行脚本 | STF |
onmousedown | 脚本 | 在元素区域内按下鼠标键(不区分左右键)时执行脚本 | STF |
onmousemove | 脚本 | 当鼠标指针在元素区域内移动时执行脚本 | STF |
onmouseout | 脚本 | 当鼠标指针移出元素区域时执行脚本 | STF |
onmouseover | 脚本 | 当鼠标指针移入元素区域时执行脚本 | STF |
onmouseup | 脚本 | 在元素区域内松开鼠标键(不区分左右键)时执行脚本 | STF |
onkeydown | 脚本 | 按下一个键时执行脚本 | STF |
onkeypress | 脚本 | 按下并松开一个键时执行脚本 | STF |
onkeyup | 脚本 | 松开一个键时执行脚本 | STF |

HTML is a language used to build web pages, defining web page structure and content through tags and attributes. 1) HTML organizes document structure through tags, such as,. 2) The browser parses HTML to build the DOM and renders the web page. 3) New features of HTML5, such as, enhance multimedia functions. 4) Common errors include unclosed labels and unquoted attribute values. 5) Optimization suggestions include using semantic tags and reducing file size.

WebdevelopmentreliesonHTML,CSS,andJavaScript:1)HTMLstructurescontent,2)CSSstylesit,and3)JavaScriptaddsinteractivity,formingthebasisofmodernwebexperiences.

The role of HTML is to define the structure and content of a web page through tags and attributes. 1. HTML organizes content through tags such as , making it easy to read and understand. 2. Use semantic tags such as, etc. to enhance accessibility and SEO. 3. Optimizing HTML code can improve web page loading speed and user experience.

HTMLisaspecifictypeofcodefocusedonstructuringwebcontent,while"code"broadlyincludeslanguageslikeJavaScriptandPythonforfunctionality.1)HTMLdefineswebpagestructureusingtags.2)"Code"encompassesawiderrangeoflanguagesforlogicandinteract

HTML, CSS and JavaScript are the three pillars of web development. 1. HTML defines the web page structure and uses tags such as, etc. 2. CSS controls the web page style, using selectors and attributes such as color, font-size, etc. 3. JavaScript realizes dynamic effects and interaction, through event monitoring and DOM operations.

HTML defines the web structure, CSS is responsible for style and layout, and JavaScript gives dynamic interaction. The three perform their duties in web development and jointly build a colorful website.

HTML is suitable for beginners because it is simple and easy to learn and can quickly see results. 1) The learning curve of HTML is smooth and easy to get started. 2) Just master the basic tags to start creating web pages. 3) High flexibility and can be used in combination with CSS and JavaScript. 4) Rich learning resources and modern tools support the learning process.

AnexampleofastartingtaginHTMLis,whichbeginsaparagraph.StartingtagsareessentialinHTMLastheyinitiateelements,definetheirtypes,andarecrucialforstructuringwebpagesandconstructingtheDOM.


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

DVWA
Damn Vulnerable Web App (DVWA) is a PHP/MySQL web application that is very vulnerable. Its main goals are to be an aid for security professionals to test their skills and tools in a legal environment, to help web developers better understand the process of securing web applications, and to help teachers/students teach/learn in a classroom environment Web application security. The goal of DVWA is to practice some of the most common web vulnerabilities through a simple and straightforward interface, with varying degrees of difficulty. Please note that this software

VSCode Windows 64-bit Download
A free and powerful IDE editor launched by Microsoft

MinGW - Minimalist GNU for Windows
This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.

ZendStudio 13.5.1 Mac
Powerful PHP integrated development environment

WebStorm Mac version
Useful JavaScript development tools