Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to solve the problem of sending ajax garbled codes

2025-01-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/02 Report--

This article mainly explains "how to solve the problem of sending ajax garbled code", interested friends may wish to have a look. The method introduced in this paper is simple, fast and practical. Let's let the editor take you to learn "how to solve the problem of sending ajax garbled codes".

The solution to sending ajax garbled codes: 1, check whether the character interceptor is configured in web.xml; 2, change the jsp page to utf-8;3, and change the ajax request to post request.

This article operating environment: windows7 system, jquery3.2.1 version, Dell G3 computer.

How to solve the problem of sending ajax garbled codes?

Resolve the problem of Chinese garbled code when JQuery sends ajax request:

First troubleshoot the project:

Whether a character interceptor is configured in 1.web.xml

EncodingFilter org.springframework.web.filter.CharacterEncodingFilter encoding utf-8 forceEncoding true encodingFilter / *

Is the 2.jsp page utf-8?

Add this tag by the way, send utf-8 uniformly, but I heard that there are some chicken ribs.

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.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report