html - Is a URL allowed to contain a space? -


Is a URI (specifically a HTTP URL) allowed to include one or more space characters? If a URL is must encoded, then what is + just a follow up convention, or is there a valid option?

Inspiration for the question:

/ Strong> Beta-testing of a web site, I saw That some URLs were created with spaces in them. Firefox did the right thing, which surprised me! But I wanted the developers to be able to point to RFC so that they could feel the need to fix those URLs.

According to

:

unsafe:

Characters can be unsafe for many reasons Space character is unsafe because important spaces can be missing and comparable places can be presented when URL is transcripted or subjected to treatment of typeset or word processing program. The letter " and "& gt;" are unsafe because they are used in the free text as a delimiter around the URL; In some systems the quotation marks ( "" ) are used to delimit the URL. Character "#" is unsafe and should always be encoded because It is used in the World Wide to delimit the URL from a piece / anchor identifier in the web and other systems which can follow it. The character "%" is unsafe because it uses other characters K A Other characters are unsafe because the gateways and other transport agents are sometimes known to modify such characters. "{" , "} ", " | ", " \ ", " ^ ", " ~ " "[" , "]" , and "` ".

Any insecure characters always have any The URL should be encoded within. For example, the letter encoding within the "#" URL Ahia the system in general, not to deal with the piece or anchor identifiers, so the URL copy that to which add another system to use them, you will not need to change the URL encoding.


Comments