W3C home > Mailing lists > Public > www-validator@w3.org > May 2010

RE: reference to undeclared general entity nbsp

From: Tatham Oddie <tatham@oddie.com.au>
Date: Wed, 19 May 2010 19:24:59 -0400
To: Pierre Rudloff <tael67@gmail.com>, "www-validator@w3.org" <www-validator@w3.org>
Message-ID: <8F713F6B2CE37349BBD122288FBD015485D36D50@MBX02.netplexity.local>


In your question you mentioned that you were using HTML5. Based on this
error, I'm assuming that you're doing this with an XML based encoding. (If
this is not the case, please send us a link to the actual page in question
or the full markup snippet.)


Named character entities are a bit different between HTML and XML.


You can see here that non-breaking spaces aren't defined in XML (and thus




Never the less, you can always use its numeric representation (&#160;) in
XML if you want.


Finally, in many cases you're better off using white-space: nowrap; in CSS
to achieve the same visual style without having to add extra markup.




Tatham Oddie

au mob: +61 414 275 989, us cell: +1 213 280 9140, skype: tathamoddie


From: www-validator-request@w3.org [mailto:www-validator-request@w3.org] On
Behalf Of Pierre Rudloff
Sent: Wednesday, 19 May 2010 8:36 PM
To: www-validator@w3.org
Subject: reference to undeclared general entity nbsp


When checking a HTML5 page via direct input, I got this error :
"reference to undeclared general entity nbsp"
I don't understand, is &nbsp; not a valid way to insert non-breaking spaces

Pierre Rudloff

NOTE: Whenever possible, give the address of the document you were checking.

Received on Wednesday, 19 May 2010 23:25:41 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:31:04 UTC