After testing python's urllib library and js's encodeURIComponent, they will not be replaced. Space encode is also replaced with '%20'. Python provides urllib.quote_plus, urlib.unquote_plus to handle spaces->plus signs, which seems reasonable.
I checked RFC 3986: there is the following paragraph
Scheme names consist of a sequence of characters beginning with a letter and followed by any combination of letters, digits, plus ("+"), period ("."), or hyphen ("-").
RFC 2396 has the following paragraph
The plus "+", dollar "$", and comma "," characters have been added to those in the "reserved" set, since they are treated as reserved within the query component.
means that the plus sign is already a reserved word of the URL and does not need to be escaped.
Then there is the escape of the plus sign in the html4 document:
application/x-www-form-urlencoded
Forms submitted with this content type must be encoded as follows:
Control names and values are escaped. Space characters are replaced by `+', and then reserved characters.....
Declare + only when content-type is application/x-www-form-urlencoded Do escaping.
Looking through the php documentation again, I found a
rawurlencode() - URL-encode according to RFC 3986
That is, php has done rawurlencode again and rawurldecode implement the standard. . . .
Can’t you reverse it? After all, most people should be able to use urlencode. php is such a pain in the ass. . . .