ComputersProgramming

Encoding html. How are web pages painted?

As a way of encoding information for its transmission over the Internet, the html encoding is used. The determining parameter during this process is the number of bits involved, it is with their help that a particular symbol is transmitted. So one bit encodes a pair of values, two bits are calculated for the encoding of four values, three bits for eight. Adding a bit, you can double the number of encoded values. So, 8 bits are able to encode 256 sequences (values) in binary code. A notable feature is that each sequence retains the ability to transmit one text symbol. An alternative to encoding with eight bits is the encoding of 16 and 32-bit, they are already able to process 65536 and, accordingly, 4294967296 text characters.

Opening the Internet Explorer browser included in the Windows OS, you can see in the menu item "View - Encoding" an extensive list of different encodings. It should be remembered that the Russian html encoding is represented by six main tables that support Cyrillic. The most common among them is Windows-1251, followed by ISO-8859-5, UTF-8, KOI-8R, KOI-8U, and there is also a Russian-language encoding for the Mac environment.

The html encoding allows you to display information correctly on a web page. Thanks to the existing protocol, there is an exchange between the server and the web browser of the service information, which contains exhaustive data about the method used to encode the text.

Using the HTTP protocol, the process of sending a message from the web browser to the server of messages is received, the server retrieves the necessary page and translates it (recodes) into the required format. If there is no document on the server (web page), it becomes necessary to select the necessary encoding yourself (manually).

The html encoding allows you to set the parameters of the page being loaded. After all, the rating of a web resource depends on the correctness of the perception of its browsers by users. For example, even the color scheme used on the page is specified using the code.

The encoding of html colors occurs by specifying the required shade in the gradations of the primary colors. To obtain the desired color on the monitor, it is necessary to mix the primary colors - red, green and blue. So, the record in the RGB code for pure red color looks like rgb (255,0,0). The numeric set in parentheses for green will be represented by a selection of 0.255.0, for blue - 0.0255. Classically, the yellow color is encoded by a combination of 255.255.0, and the code 255.0255 corresponds to the purple one. In black, the combination looks like 0,0,0, for the white 255,255,255, and for the gray 192,192,192.

The above color representation is given for greater clarity, the html encoding assumes the use of a hexadecimal notation (HEX), which starts with the # sign. When writing in the HEX code, the black color will be represented as # 000000, the white color is #FFFFFF, and the gray color is # C0C0C0. The primary color coding for red, green and blue will look like # FF0000, # 00FF00, # 0000FF, respectively.

The W3C Consortium uses 16 colors, valid for HTML and CSS. For them, the names are aquamarine (aqua), blue, black, fuchsia, green, gray, lime or lime, ultramarine (navy), chestnut (maroon ), Olive, red, purple, silver, white, teal and yellow. For colors that are not included in this list, it is more correct to use the HEX or RGB code.

A few years ago, the notion of "safe colors" was widespread, limiting the range of colors used in the creation of web pages to 216 web colors. The development of computer technology has removed any restrictions on this issue.

Similar articles

 

 

 

 

Trending Now

 

 

 

 

Newest

Copyright © 2018 en.unansea.com. Theme powered by WordPress.