Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Method for processing Chinese disorderly codes submitted in get mode in jsp (java server pages)

A Chinese and method technology, applied in special data processing applications, instruments, electrical and digital data processing, etc., can solve problems such as high cohesion, affecting user experience, and low coupling, and achieve the effect of enhancing user experience.

Inactive Publication Date: 2015-04-01
G CLOUD TECH
View PDF3 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

When using the get method to submit Chinese characters, you often encounter garbled characters, which seriously affects the user experience; the general solution is to modify the relevant character encoding configuration of the container (such as: tomcat), and then the server will use the character encoding of the container If you want to deploy the application on multiple servers, you need to modify the character encoding settings for each container, which is very inconvenient. Because this solution has a strong dependence, it does not conform to the basic idea of ​​​​software design : High cohesion and low coupling

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method for processing Chinese disorderly codes submitted in get mode in jsp (java server pages)
  • Method for processing Chinese disorderly codes submitted in get mode in jsp (java server pages)
  • Method for processing Chinese disorderly codes submitted in get mode in jsp (java server pages)

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0016] Such as figure 1 As shown, Chinese characters are URL-encoded twice before submitting Chinese through the jsp page get method, and then URL decoding is performed on the server side again. The specific steps are as follows:

[0017] Step 1: Obtain the path of the jsp page get method to submit the request, that is, the url;

[0018] Step 2. Determine whether there are Chinese parameters in the url. If there are Chinese characters, encode the Chinese characters twice. The attached code is as follows:

[0019]

[0020]

[0021] Step 3: After the server Action or Servlet receives the parameters, it decodes the URL again. The attached code is as follows:

[0022] / / Background server code

[0023] String str=java.net.URLDecoder.decode(tt,"utf-8"); / / Decode URL once.

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention relates to the technical field of software technology development, in particular to a method for processing Chinese disorderly codes submitted in a get mode in jsp (java server pages). The common problem of Chinese disorderly codes in the development process is solved by performing secondary URL (uniform resource locator) encoding and URL decoding for Chinese characters submitted in the get mode in jsp. The method is independent of configuration of a container, and can be used for processing the Chinese disorderly codes submitted in the get mode in the jsp flexibly and conveniently without correcting relevant configurations of a system.

Description

technical field [0001] The invention relates to the technical field of software technology development, in particular to a method for solving the problem of submitting Chinese garbled characters in a get mode in jsp. Background technique [0002] The current business system is not only more and more complex, but also has higher and higher user experience requirements. Many websites or systems are developed by jsp technology. When using the get method to submit Chinese characters, you often encounter garbled characters, which seriously affects the user experience; the general solution is to modify the relevant character encoding configuration of the container (such as: tomcat), and then the server will use the character encoding of the container If you want to deploy the application on multiple servers, you need to modify the character encoding settings for each container, which is very inconvenient. Because this solution has a strong dependence, it does not conform to the ba...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Applications(China)
IPC IPC(8): G06F17/30G06F17/22
CPCG06F40/126
Inventor 齐兆勇徐震宇孙傲冰季统凯
Owner G CLOUD TECH
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products