IE7/8 when the text mode is miscellaneous & quot; Quirks & quot;, leading to JSP page variations, ie7quirks

Source: Internet
Author: User

IE7/8 when the text mode is miscellaneous "Quirks", leading to JSP page variations, ie7quirks

Possible causes:

1. jsp page header Encoding Problems. For example:

<%@ page language="java" contentType="text/html; charset=UTF-8"%>

 

Solution to this problem:

1. jsp page header encoding problem, solution:

Set

<%@ page language="java" contentType="text/html; charset=UTF-8"%>

Change

<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>

 

Why?

I am not very clear, just know it, but I don't know why, just do this record ...... Thank you!

After finding the information, IBM should be reliable:

JSP page instructions for setting industry-level code

<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>

In the page directive of this line, "text/html; charset = UTF-8" sets "Content-type" in the Response Message to "text/html; charset = UTF-8 ".
"PageEncoding" only specifies the encoding format of the JSP page and the encoding method used to save the JSP page. When the container reads the file, it converts it to the Unicode used internally. When the response is sent back to the browser, the container converts the Unicode used internally to the character set specified in Content-type.
If PageEncoding is not specified, you can use the character set specified by Content-type to explain the JSP page bytes.
To properly display characters encoded by the UTF-8, the following two conditions must be met:
1. the character set used to notify the browser to respond to a message.
2. Configure the browser so that it can properly display UTF-8-encoded fonts.

Copyright Disclaimer: This article is an original article by the blogger and cannot be reproduced without the permission of the blogger.

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.