URL special character escape

Source: Internet
Author: User

The Basic Encoding Rules are as follows:
1. Replace space with the plus sign (+)
2. The forward slash (/) is used to separate directories and subdirectories.
3. Question mark (?) Separate URLs and queries
4. Specify special characters for the percent sign (% ).
5. # specifying bookmarks
6. & # separator Parameters
If you need to use these special characters in the URL, You need to replace them with the corresponding hexadecimal value.

Character URL encoding Value
Space % 20
"% 22
# % 23
% 25
& % 26
(% 28
) % 29
+ % 2B
, % 2C
/% 2f
: % 3A
; % 3B
<% 3C
= % 3d
> % 3E
? % 3f
@ % 4O
\ % 5c
| % 7c
Generally, a page is written and parsed using the decodeuri or decodeuricomponent function of Js.

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.