In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-31 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/03 Report--
Editor to share with you how to solve html Chinese garbled code, I believe that most people do not know much about it, so share this article for your reference, I hope you can learn a lot after reading this article, let's go to understand it!
HTML Chinese garbled is generally caused by a mismatch in the coding format, so you only need to use meta tags to match the encoding format in the head part of the HTML document.
The operating environment of this tutorial: windows7 system, HTML5 version, Dell G3 computer.
In the web page, we sometimes see a long list of Chinese garbled codes.
Title
This is a test text!
In fact, the cause of Chinese garbled code is generally caused by the mismatch of the coding format, as long as it matches the coding format of the html file.
There are three ways to encode in HTML: gb2312,gbk,utf-8; most browsers now code utf-8 by default. We only need to use the tag to set the HTML encoding mode to utf-8 to solve the problem of garbled codes in html.
Add a tag to the head node and declare the character as UTF-8
Title
This is a test text!
Description:
Tags provide metadata for HTML documents. The metadata will not be displayed on the client side, but will be parsed by the browser.
The META element is usually used to specify the description of the web page, keywords, the last modification time of the file, the author, and other metadata. Metadata can be invoked using browsers (how to display content or reload pages), search engines (keywords), or other Web services.
The charset attribute of the tag specifies the character encoding of the HTML document.
The charset property is a new property in HTML5 and replaces:
The http-equiv attribute is still allowed to specify the character set, but using the new method can reduce the amount of code.
The above is all the contents of the article "how to solve Chinese garbled in html". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.