# Tidy 61

## Tidy: URI reference contains backslash. Typo?

### Cause:

There is a backslash in a URI.

Although backslashes are acceptable in theory within URLs, in practice they are usually due to following the Windows custom of using backslashes as path separators instead of using forward slashes (the accepted path separator in a URI), or the Unix custom of escaping special characters by backslashes, instead of using percent-escaping (the accepted URI format).









### Solution:

• Make sure that only forward slashes are used as path separators in URIs
• Special characters (normally not accepted in a URI) can be represented by their hex value preceded by a percent sign
• As shown in the (somewhat contrived) last example above, for characters above 127 the UTF-8 representation is percent-escaped one byte at a time.