Welcome to WebmasterWorld Guest from 52.91.176.251

Forum Moderators: open

Message Too Old, No Replies

Error "No Space Between Attributes"

Firefox View Source Screen Shows Red Links

     
4:17 am on Jul 22, 2013 (gmt 0)

New User

10+ Year Member

joined:Oct 17, 2004
posts: 25
votes: 0


When I check my page source in Firefox, I see that some of my links are in red. Those in red show a title popup of "No Space Between Attributes".

I cannot find a definition of this message. Is it an error, will it affect search, where do I look to figure out what this message is trying to tell me?

Thanks for your help on this.
6:25 pm on July 22, 2013 (gmt 0)

Senior Member from GB 

joined:Oct 2, 2003
posts: 1019
votes: 39


Hi there j_a_c_k,

...what is this message trying to tell me?


Well, apart from the obvious, it is pointing out your mildly sloppy coding. ;)

We all do it sometime or other, especially if C&P'ing code.

I treat it as a helpful aid. :)

birdbrain
7:18 pm on July 22, 2013 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member lucy24 is a WebmasterWorld Top Contributor of All Time 5+ Year Member Top Contributors Of The Month

joined:Apr 9, 2011
posts:15450
votes: 739


Might help if you posted a couple of sample <a> elements to show which ones are red and which aren't.

I don't normally use FF for viewing source, so I'm not familiar with their color coding-- but this in turn means I haven't changed the defaults. Looks like all html entities are red. And in the sample page I looked at, the entire DTD was also red, with a popup saying rudely that they expected "doctype html" and that's all. Lissen, FF, it's entirely my own business what doctype I choose to use, so long as it's valid-- and in this particular case it was an e-book where we're not ALLOWED to use HTML 5 yet, so don't tell me, tell Project Gutenberg. Hmph.
7:40 pm on July 22, 2013 (gmt 0)

Senior Member from GB 

joined:Oct 2, 2003
posts: 1019
votes: 39


Hi there Lucy,

Might help if you posted a couple of sample <a> elements to show which ones are red and which aren't.

There is really no need for that.

The O.P. was rather vague.

It is the code in "View Source" to which she/he refers rather than it's rendering. :)

"View Source" in Firefox shows attribute name/value pairs in black/blue.

When space is lacking between attributes then the whole tag is shown in red.

birdbrain
9:26 pm on July 22, 2013 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member lucy24 is a WebmasterWorld Top Contributor of All Time 5+ Year Member Top Contributors Of The Month

joined:Apr 9, 2011
posts:15450
votes: 739


It is the code in "View Source" to which she/he refers rather than it's rendering

Fer hevvins sakes, I understood that. (Uh, didn't the remainder of my post make this clear?)

When space is lacking between attributes then the whole tag is shown in red.

Does red simply mean "This is something we don't like"?

:: back to re-check something ::

In view of their reaction to the DTD, I thought they might be highlighting only those entities that HTML 5 doesn't approve of (apparently everything but &amp; &lt; &gt; ?) but nope, &amp; looks the same as the others.

Shrug.
10:03 pm on July 22, 2013 (gmt 0)

Senior Member from GB 

joined:Oct 2, 2003
posts: 1019
votes: 39


Hi there Lucy,

Uh, didn't the remainder of my post make this clear?

Actually, I have great difficulty in understanding anything that you write
in your numerous posts. :(

This, of course, may not be your fault, but perhaps be due to our different
global locations or possibly a certain amount of obtuseness on my part. ;)

birdbrain
7:51 am on July 23, 2013 (gmt 0)

Senior Member from GB 

joined:Oct 2, 2003
posts: 1019
votes: 39


Hi there Lucy,

Looking long and carefully at your original post, I did manage to inwardly digest this...

And in the sample page I looked at, the entire DTD was also red


I would suggest that there is probably a fault in your dtd. :(

I use either...
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">

...or...
<!DOCTYPE html>

...and they are both shown in a rather delicate shade of blue. ;)

birdbrain
8:34 am on July 23, 2013 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member lucy24 is a WebmasterWorld Top Contributor of All Time 5+ Year Member Top Contributors Of The Month

joined:Apr 9, 2011
posts:15450
votes: 739


Hm

:: scratching head ::

Cut-and-paste from the code I use in all ebooks (they prefer XHTML but you gotta draw the line somewhere) so I know there's no validation-level problem:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">


But the popup didn't say there's some specific problem. It just sulked that it expected "html" alone.

Further experimentation with random commercial sites pulled up from browser history suggests that maybe they just don't like Transitional, period. (What the ### business is it of theirs?) Here's another one in red from recent browser history:

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">


:: tweet tweet, chirp chirp ::
1:13 pm on July 23, 2013 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member fotiman is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:Oct 17, 2005
posts: 5019
votes: 24


Well, the Transitional DTD was meant to be just that... "transitional". That transition period has long passed, so you shouldn't be using that one any more. :)

maybe they just don't like Transitional, period. (What the ### business is it of theirs?)

Umm... well... since they (the browser) is the one rendering the page, I'd say it's their business. I noticed that on WebmasterWorld the tooltip on the DOCTYPE says

Quirky doctype. Expected "<!DOCTYPE html>".

So perhaps the warning is really just meant as "this DTD will trigger quirks mode, and as such is less cross-browser friendly"? Of course, WebmasterWorld is using a DOCTYPE that will trigger quirks mode (*shakes head*).
Just a guess, though. I don't think the "Expected" statement necessarily means that they ONLY expected an HTML5 doctype. It might just mean they expected something that would trigger standards mode instead?
10:10 pm on July 23, 2013 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member lucy24 is a WebmasterWorld Top Contributor of All Time 5+ Year Member Top Contributors Of The Month

joined:Apr 9, 2011
posts:15450
votes: 739


I re-checked mine. It says "Almost standards mode doctype" before the "Expected..." part. ALMOST? C'mon, FF, give us a hint. Missing a space? Extra space? LF alone where you expected CRLF? Also re-checked with the validator; no complaints.

"Transitional" is an oddly chosen word anyway. It doesn't really mean "on the way from point A to point B", it simply means "you're allowed to put things in the HTML that we'd prefer to see in CSS". That means, for example, you can say <blahblah align = "center"> where Strict would insist on <blahbalh style = "text-align: center";> using twice as many words to achieve identical results. Please do not deduce from this that I ever, at any time, under any circumstances, use <font> tags. Let's be reasonable.
10:37 pm on July 23, 2013 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member fotiman is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:Oct 17, 2005
posts: 5019
votes: 24


[en.wikipedia.org...]
See the section that talks about Almost Standards mode (Transitional DOCTYPEs will trigger this).

In strict, presentation attributes would be disallowed, and PREFERABLY put in an external stylesheet (as opposed to using inline style elements). Sure, you *COULD* use inline styles, but "could" and "should" are very different words. :)
11:10 pm on July 23, 2013 (gmt 0)

Senior Member from GB 

joined:Oct 2, 2003
posts: 1019
votes: 39


Hi there Lucy,

I cannot, for the life of me, understand why you are
complaining about Firefox's display of "Source Code.

It is the only browser, amongst my testers, that
gives indications of sloppy coding.

To me, that makes it a handy tool, to you, it just
seems to be an irritation.

birdbrain

[edited by: bill at 2:40 am (utc) on Jul 24, 2013]
[edit reason] tidy up [/edit]

11:35 pm on July 23, 2013 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member lucy24 is a WebmasterWorld Top Contributor of All Time 5+ Year Member Top Contributors Of The Month

joined:Apr 9, 2011
posts:15450
votes: 739


Sure, you *COULD* use inline styles, but "could" and "should" are very different words.

Yes, that's the thing about "Strict" that always riled me. I could never see why <blahblahh style = "text-align: center";> is OK while <blahblah align = "center"> is not.

Along the way, I noticed that there must be a Mozilla Blue, because the color FF uses-- in, ahem, elements it doesn't object to-- is identical to what Camino uses for the same elements :) But if I'm really going to study a page's source code, I prefer to paste it into SubEthaEdit which offers an even more detailed range of color coding.

[edited by: bill at 2:41 am (utc) on Jul 24, 2013]
[edit reason] tidy up [/edit]

 

Join The Conversation

Moderators and Top Contributors

Hot Threads This Week

Featured Threads

Free SEO Tools

Hire Expert Members