Your Search Results

    HTML

    重定向自 https://developer.mozilla.org/zh-CN/docs/XPInstall

    Redirected from https://developer.mozilla.org/en-US/docs/HTML

    This article is in need of an editorial review.

    HyperText Markup Language (HTML) is a makup language used for creating and visually representing a webpage. It is the external appearance of every webpage.Apart from visual images,it supports media as well. More precisely, HTML is the language that describes the structure and the semantic content of a web document. Content within a web page is tagged with HTML elements such as <img>, <title>, <p>, <div>, and so forth.These elements form the building blocks of a website.

    The articles here provide reference materials you can refer to while you develop for the web.

    • HTML reference

      In our extensive reference, you'll find the details on every element and attribute that make up HTML.

    • HTML guide

      For articles about how to use HTML, as well as tutorials and complete examples, check out our HTML developer guide.

    • HTML introduction

      If you're new to Web development, be sure to read our introduction to what HTML is and how to use it.

    References

    Block-level elements
    "Block-level" is categorization of HTML (Hypertext Markup Language) elements, as contrasted with "inline" elements. Block-level elements may appear only within a <body> element. Their most significant characteristic is that they typically are formatted with a line break before and after the element (thereby creating a stand-alone block of content). That is, they take up the width of their containers.
    CORS enabled image
    The HTML specification introduces a crossorigin attribute for images that, in combination with an appropriate CORS header, allows images defined by the <img> element loaded from foreign origins to be used in canvas as if they were being loaded from the current origin.
    CORS settings attributes
    In HTML5, some HTML elements which provide support for CORS, such as <img> or <video>, have a crossorigin attribute (crossOrigin property), which lets you configure the CORS requests for the element's fetched data. These attributes are enumerated, and have the following possible values:
    Canvas
    Added in HTML5, the HTML <canvas> element can be used to draw graphics via scripting in JavaScript. For example, it can be used to draw graphs, make photo compositions, create animations or even do real-time video processing or rendering.
    Controlling spell checking in HTML forms
    Firefox 2 introduces spell checking support to text areas and text fields in web forms. The user can specify using the about:config interface whether or not spellchecking is enabled and whether to check both text areas and text fields or only text areas.
    DASH Adaptive Streaming for HTML 5 Video
    Dynamic Adaptive Streaming over HTTP (DASH) is an adaptive streaming protocol. This means that it allows for a video stream to switch between bit rates on the basis of network performance, in order to keep a video playing.
    Focus management in HTML
    In the HTML5 working draft, the activeElement DOM attribute and the hasFocus() DOM method give the programmer the ability to have better control of the interactivity of the page due to the user's actions. For example, both of them can be used for statistical usage purposes, tracking the number of clicks on certain links of a page, measuring the amount of time an element is focused, and so forth. In addition, when combined with AJAX technology, they help minimize the number of requests to the server, depending on the user activity and the page layout.
    Global attributes
    HTML defines a few attributes that are common to all HTML elements. These attributes can be used on all elements, though the attributes may have no effect on some elements.
    HTML attribute reference
    Elements in HTML have attributes; these are additional values that configure the elements or adjust their behavior in various ways to meet the criteria the users want.
    HTML documentation index
    Found 154 pages:
    HTML element reference
    This page lists all standard HTML tags, including both the latest HTML5 tags, as well as older ones (including both obsolete and non-standard tags) tags.
    HTML reference
    HTML is the language that describes the structure and the semantic content of a Web document; it consists of elements, each of which may be modified by some number of attributes.
    Inline elements
    "Inline" is categorization of HTML elements, as contrasted with "block-level" elements. Inline elements can appear within block-level or other inline elements. They take up the width of their contents. The differences between inline and block-level elements include:
    Link types
    In HTML, the relationship between two documents, in which one links to the other using an <a>, <area>, or <link> element, can be specified as one of these link types.
    Manipulating video using canvas
    By combining the capabilities of the video element with a canvas, you can manipulate video data in real time to incorporate a variety of visual effects to the video being displayed.  This tutorial, adapted from this blog post by Paul Rouget, demonstrates how to perform chroma-keying (also known as the "green screen effect") using JavaScript code.
    Media formats supported by the HTML audio and video elements
    The <audio> and <video> elements provide support for playing audio and video media without requiring plug-ins. Video codecs and audio codecs are used to handle video and audio, and different codecs offer different levels of compression and quality. A container format is used to store and transmit the coded video and audio (both together, the case of a video with a soundtrack). Many combinations of codecs and container formats exist, although only a handful of these are relevant on the Web.
    Optimizing your pages for speculative parsing
    Traditionally in browsers the HTML parser has run on the main thread and has blocked after a </script> tag until the script has been retrieved from the network and executed. The HTML parser in Firefox 4 and later supports speculative parsing off the main thread. It parses ahead while scripts are being downloaded and executed. As in Firefox 3.5 and 3.6, the HTML parser starts speculative loads for scripts, style sheets and images it finds ahead in the stream. However, in Firefox 4 and later the HTML parser also runs the HTML tree construction algorithm speculatively. The upside is that when a speculation succeeds, there's no need to reparse the part of the incoming file that was already scanned for scripts, style sheets and images. The downside is that there's more work lost when the speculation fails.
    Using the application cache
    HTML5 provides an application caching mechanism that lets web-based applications run offline. Developers can use the Application Cache (AppCache) interface to specify resources that the browser should cache and make available to offline users. Applications that are cached load and work correctly even if users click the refresh button when they are offline.

    View All...

    Guides and tutorials

    HTML developer guide
    MDN articles demonstrating specific techniques you can use when building Web content with HTML, as well as tutorials and other material you may find handy.

    Join the Web layout community

    Choose your preferred method for joining the discussion: