From: http://hi.baidu.com/jrckkyy/blog/item/d86c12ecea120c30279791be.html
In addition to common letters, numbers, Chinese characters, and special characters, character escaping is used."+" The + sign in the URL indicates space % 2BThe space in
From: http://www.javaeye.com/topic/483158
Application 1: solves the problem of Chinese garbled characters in Tomcat (a simple one first)
In tomcat, we usually solve the Chinese Garbled text problem as follows:
Filter code:Java code
Package
The path to obtain the previous page address is often encountered. You can return to the previous page for use to implement this operation through JS. The following is a good example. you can refer to the actual project process, we often encounter
In the normal development of Web sites, we have to deal with URLs, we can access specific addresses through a URL, we can pass the URL we need to test parameters, so how to get the parameters in the URL becomes important. This blog post will be how
The path to obtain the previous page address is often encountered. You can return to the previous page for use to implement this operation through JS. The following is a good example. you can refer to the actual project process, we often encounter
thinkphp Remove the index.php in the URL, absolutely works!
For example, your original path is Http://localhost/test/index.php/index/add So now the address is Http://localhost/test/index/add How to get rid of index.php? The mod_rewrite.so
Recently wrote a program in PHP (UTF8 encoding) found that the HTTP get to send an odd number of Chinese characters to the server side will appear garbled, just beginning to think PHP program or service configuration problems.
Later checked for a
In iOS apps, it's common to see apps jump directly to the App Store page with a click action, and start to wonder how this third party applies to iOS system application interactions. It was later found that the implementation of this communication
from a page through the URL to the B page, get the URL of the parameters in Chinese garbled problem, the correct way to parse the URL parameters are as follows, interested friends can refer to the following When you pass a page through a URL to
URLs appear with +, spaces,/,?,%,#,&,= and other special symbols, may not be able to get the correct parameter value on the server side, how is good. Workaround: Convert these characters into characters that the server can recognize, corresponding
In the optimization of the site, URL optimization is often overlooked one aspect, but the URL optimization is also very important, here and you talk about how I deal with these problems, I hope that these experience to help you!
1: The choice of
When processing Javascript on the frontend only, you may encounter a problem of passing a webpage parameter to the next page through the get method. In this case, you can obtain the Get parameter in the Url, as shown below, if you need it, you may
This article mainly introduces the PHP replacement URL parameters, has a certain reference value, now share to everyone, the need for friends can refer to
0) $url _array[$i]= "&". $url _array[$i]; $new _url= $new _url. $url
PageCode
Private
Void
Button2_click (
Object
Sender, system. eventargs E){Response. Redirect (
"B. aspx
? Name = Database Error
"
);}
We recommend that you encode server. urlencode for "database error" and then upload it. So
I also encountered the above problems, so I recorded them. always phenomenon is: spring uses forward ("/WEB-INF/JSP /*. JSP ") while forward certainly goes through the Web. XML ing, then, when the URL matches, URL-pattern /
Javascript: the pseudo-Protocol qualifier indicates that the URL content is an arbitrary string of the JavaScript code to be run by the javascript interpreter. A javascript URL is as follows:
javascript:var now=new Date();"The time is :"+now;
When
When passing the parameter value through the link is Chinese, there will be 2 problems: (the page uses the UTF-8 format) 1 "Chinese garbled, in the action when the value of transcoding can be (use new string (Str. getbytes ("iso-8859-1"), "UTF-8") 2
thinkphp Remove the index.php in the URL, absolutely works!
For example, your original path is http://localhost/test/index.php/index/add.So now the address is http://localhost/test/index/add.How to get rid of index.php?The mod_rewrite.so module
When investigating an error, I accidentally found that some links on the HTML page contain +, decompiled the tag, and found that the java.net. urlencoder method was called.
Public static string encode (string S, string ENC)
From the code, we can
Chinese garbled is the Web site development will often encounter problems, today we talk about the URL address in Chinese character parameters to pass garbled solution, there is a need for friends can refer to.In the CS file in the time to pass the
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.