1. Basic concepts encodeURI and decodeURI are used in pairs, because if there are Chinese characters in the browser's address bar, unexpected errors may occur, so encodeURI can convert non-English characters For English encoding, decodeURI can be used to restore characters back. The encodeURI method does not encode the following characters: ":", "/", ";" and "?", the encodeURIComponent method can encode these characters.
decodeURI() method is equivalent to java.net.URLDecoder.decode(URIString, "UTF-8");
encodeURI() method is equivalent to java.net.URLEncoder.encode(URIString, "UTF-8" ; 🎜>