HTML is the unified language of the Web. These rough tags contained in angle brackets constitute today's Web. In 1991, Tim Berners-Lee wrote a document called "HTML Tags", which includes about 20 HTML tags used to mark web pages. He directly borrowed the markup style of SGML, which is the HTML markup style we saw later.
Today, the editor of Huwu will sort out the html5 cold knowledge that you may not know.
Run the browser address barJavaScriptCode
Many people should still know this. You can run JavaScript code directly in the browser address bar. The method is to start with javascript: followed by execution statement. For example:
Chr Ome will automatically remove the javascript: at the beginning of the code, so it needs to be added manually for correct execution. Although Firefox will not automatically remove it, it does not support running JS code in the address bar at all! !
Run HTML code in the browser address barIf more people know the little secret above, fewer people know this tip. In non-IE core browsers The address bar can run HTML code directly!
Editor Still making a fuss on the browser address bar, paste the following code into the address bar and run it, and the browser will become a primitive and simple editor, just like the notepad that comes with Windows, roar Roar.
attribute, when the element is specified with this attribute, the content of the element becomes editablestate.
By extension, after putting the following code into the console and executing it, the entire page will become editable!
##Use a tag to automatically parse URL
query
keywords,variablesparameter values, etc., but we never expected that the browser can easily help We accomplish this task without writing regular code to capture it. The method is to first create an a tag in the JS code and then assign the URL that needs to be parsed to the href attribute of a, and then we get everything we want.
As shown below:
Use the above method to Browser parameters to operate!
Elements with IDs on the page will create global variables
In an HTML page, all elements with ID attributes set will create corresponding global variables in the JavaScript execution environment, which means document.getElementById is as redundant as the human appendix. But in actual projects, it’s best to just write it honestly. After all, the chance of things going wrong with regular code is much smaller.
As shown below:
When loading the CDN file, You can omit the HTTP identifier
Nowadays, the popular CDN loads some common JS and CSS files from a dedicated server. For security considerations, some CDN servers use HTTPS to connect, while others use traditional HTTP, in fact, we can ignore this when using it and omit it from the URL.
Use the script tag to save any information
Set the script tag to type='text' and then you can save any information in it, and then you can Easily available in JavaScript code.
Of course, there are far more trivia than these.
【Related recommendations】
1. Free h5 online video tutorial
3. php.cn original html5 video tutorial
The above is the detailed content of Share some unpopular knowledge about html5. For more information, please follow other related articles on the PHP Chinese website!

H5 improves web user experience with multimedia support, offline storage and performance optimization. 1) Multimedia support: H5 and elements simplify development and improve user experience. 2) Offline storage: WebStorage and IndexedDB allow offline use to improve the experience. 3) Performance optimization: WebWorkers and elements optimize performance to reduce bandwidth consumption.

HTML5 code consists of tags, elements and attributes: 1. The tag defines the content type and is surrounded by angle brackets, such as. 2. Elements are composed of start tags, contents and end tags, such as contents. 3. Attributes define key-value pairs in the start tag, enhance functions, such as. These are the basic units for building web structure.

HTML5 is a key technology for building modern web pages, providing many new elements and features. 1. HTML5 introduces semantic elements such as, , etc., which enhances web page structure and SEO. 2. Support multimedia elements and embed media without plug-ins. 3. Forms enhance new input types and verification properties, simplifying the verification process. 4. Offer offline and local storage functions to improve web page performance and user experience.

Best practices for H5 code include: 1. Use correct DOCTYPE declarations and character encoding; 2. Use semantic tags; 3. Reduce HTTP requests; 4. Use asynchronous loading; 5. Optimize images. These practices can improve the efficiency, maintainability and user experience of web pages.

Web standards and technologies have evolved from HTML4, CSS2 and simple JavaScript to date and have undergone significant developments. 1) HTML5 introduces APIs such as Canvas and WebStorage, which enhances the complexity and interactivity of web applications. 2) CSS3 adds animation and transition functions to make the page more effective. 3) JavaScript improves development efficiency and code readability through modern syntax of Node.js and ES6, such as arrow functions and classes. These changes have promoted the development of performance optimization and best practices of web applications.

H5 is not just the abbreviation of HTML5, it represents a wider modern web development technology ecosystem: 1. H5 includes HTML5, CSS3, JavaScript and related APIs and technologies; 2. It provides a richer, interactive and smooth user experience, and can run seamlessly on multiple devices; 3. Using the H5 technology stack, you can create responsive web pages and complex interactive functions.

H5 and HTML5 refer to the same thing, namely HTML5. HTML5 is the fifth version of HTML, bringing new features such as semantic tags, multimedia support, canvas and graphics, offline storage and local storage, improving the expressiveness and interactivity of web pages.

H5referstoHTML5,apivotaltechnologyinwebdevelopment.1)HTML5introducesnewelementsandAPIsforrich,dynamicwebapplications.2)Itsupportsmultimediawithoutplugins,enhancinguserexperienceacrossdevices.3)SemanticelementsimprovecontentstructureandSEO.4)H5'srespo


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

Atom editor mac version download
The most popular open source editor

SublimeText3 Linux new version
SublimeText3 Linux latest version

SublimeText3 Mac version
God-level code editing software (SublimeText3)

SublimeText3 English version
Recommended: Win version, supports code prompts!

SAP NetWeaver Server Adapter for Eclipse
Integrate Eclipse with SAP NetWeaver application server.