What is the HTML space code? How to write HTML space code? Summary

Source: Internet
Author: User
At the beginning of the study of HTML, you will encounter a problem such as HTML hollow lattice how to play? Some people may directly knock the space bar, but this is not correct, after all, the space bar is not a code, so the next article will introduce you to the HTML hollow lattice code to write.

Code with five spaces in HTML

The code of the HTML hollow lattice one: (No newline space)

Let's look at a small example:

<! DOCTYPE html>

Effect:

Description: A white space is only a blank, if you want more than one space need to knock multiple characters, the space occupied by the width of the font is significantly and strongly affected.

HTML Hollow Lattice Code two: &ENSP (half-width space)

Look at a small example :


Effect:


Description: &ENSP full name is en space,en is a unit of measurement of typography, half the width of EM. By definition, it equates to half the font size (8px in 16px font), which occupies exactly 1/2 Chinese width and is largely unaffected by the font.

HTML Hollow Lattice Code three: &emsp (full-width space)

Small example:


Effect:

Description: &emsp full name is EM Space,em is the unit of measurement of typography, equivalent to the current specified number of points. For example, 1 em is 16px in a 16px font. It occupies a width of exactly 1 Chinese width, and is largely unaffected by the font.

HTML Hollow Lattice Code four: &THINSP (narrow space)

Small example:


Effect:

Description: The space is relatively thin, thin body, occupy a relatively small width. It is the one-sixth width of em.

HTML Hollow Lattice Code five: &ZWNJ (0 wide hyphenation)

Description: &zwnj is a non-printable character that is placed between two characters of the electronic text to suppress a hyphen that would otherwise have occurred, but rather to be drawn with the original glyphs of the two characters.

How to do HTML hollow lattice code six: &ZWJ (0 wide ligatures)

Description: &ZWJ is a non-printable character placed in some two characters that require complex typesetting languages (such as Arabic, Hindi), resulting in a ligature effect on the two characters that do not have a hyphen.

The following two spaces do not write an example, to learn more about HTML tags can refer to the PHP Chinese HTML manual.

This article is finished here, more exciting please pay attention to the PHP Chinese web.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.