when your viewing page source, what does red mean? im pretty sure that it means its wrong but im just double checking.

  • Which browser are you refering to? IE6 and earlier versions used notepad to view source by default and certainly do support source formatting. o.k.w almost 7 years ago
  • Oops, I meant 'do not support source formatting'. o.k.w almost 7 years ago
  • Firefox shows HTML entities in red when viewing source, e.g.   is red danwellman almost 7 years ago

2 answers

o.k.w 2355
2
points

Orta's answer about the red foward slash for self-closing element is correct. I do think that canyonchase1 is refering to the 'orangered' text as he mentioned "nbsp" of the non-breaking-space   in his comment.

For Firefox, those in orangered are HTML entities excluding the & (ampersand) prefix and the ; (semi-colon) suffix, e.g.:

  •   non-breaking space
  • & ampersand
  • — em-dash
  • © copyright
  • ™ trademark
  • etc etc

Hence these are not errors.

Answered almost 7 years ago by o.k.w
  • Great clarification +1 Gary Hepting almost 7 years ago
orta 244
1
point

Red is also used to indicate the part of a self closing element in the Firefox view source view, for things like

        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

It helps you see that you've remembered to close the tag. Extra useful when writing XHTML

Answered almost 7 years ago by orta