Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

HTML How to Make a Website Responsive Web Design and Testing Website Testing

Flavio Vento
Flavio Vento
1,542 Points

Help with an error in my HTML validation.

Line 7, Column 135: Bad value http://fonts.googleapis.com/css?family=Arimo:400,700,400italic,700italic|Fredoka+One for attribute href on element link: Illegal character in query: not a URL code point. …rimo:400,700,400italic,700italic|Fredoka+One' rel='stylesheet' type='text/css'> Syntax of URL: Any URL. For example: /hello, #canvas, or http://example.org/. Characters should be represented in NFC and spaces should be escaped as %20.

What does this mean?

Please post the block of code. You might have a mispelling.

Michele Carraglia
Michele Carraglia
790 Points

Did the trick for me too. Thanks!

4 Answers

Sean T. Unwin
Sean T. Unwin
28,690 Points

It's a warning given when there are special characters and spaces are found in an URL when validating. You don't have to worry about it, really, in this case. The warning is there because most servers don't like that sort of thing.

The Google Font URL has a pipe ('|') which the validator doesn't like and is requesting that you use escape characters for them, such as what is suggested for spaces -- %20 is the URL encoded character for a space.

Again, in the case of a Google Font URL it's generally considered okay, but if it was an href for an anchor tag pointing to a typical webpage it would likely result in an error when loading the page.

Flavio Vento
Flavio Vento
1,542 Points

Thank You Jacobus,

That worked, but why?

Jacobus Hindson
Jacobus Hindson
14,429 Points

the %7C is the equivalent of | character. Sean gives a great explanation below.

Jacobus Hindson
Jacobus Hindson
14,429 Points

the %7C is the equivalent of | character. Sean gives a great explanation below.

A short explanation plus a handy reference table for converting special characters to their URL %-encoded counterparts: http://www.w3schools.com/tags/ref_urlencode.asp

Rashid Marri
Rashid Marri
5,825 Points

i have same problem and this my code :

<link href='http://fonts.googleapis.com/css? family=Ubuntu:400,700,500,300|Lobster' rel='stylesheet' type='text/css'>