I literally grimaced when I saw the comic, and then I read the title text and my stomach churned, and then I saw the non-breaking space and I wanted to crawl up in a ball and die. lcarsos_a (talk) 06:01, 7 December 2012 (UTC)
I'm a web developer and I didn't find this annoying, although I did roll my eyes. Then I came here to see if there was anything I missed that SHOULD annoy me. No, to annoy a web developer you have to use table tags, blink tags(not supported on most browsers for good reason, annoys anybody when it works), and have a stray !-- inside a tag where it doesn't belong. Also, use any html inside your css file. And have it where it only works in IE. Ferretwilliams (talk) 06:11, 7 December 2012 (UTC)
- I'm sure Randall didn't want us to die, that's why he didn't go further. :-p Ctxppc (talk) 18:16, 7 December 2012 (UTC)
- You mean like comic 859?
It's been a long while since I coded html (I quit about the time style sheets appeared) but I think the annoying part of
is the fact that it appears as the 6 characters instead of a space, not just that it's at the end and could push the text to another line. Doesn't this typically mean that someone copied some code but didn't look carefully at the results when they pasted it into an editor? --DanB (talk) 14:27, 7 December 2012 (UTC)
- Either the title text has been parsed - in which case it's actually
<A>: Like</a> this&nbsp;(and, yes, probably copy/pasted) - or it hasn't (which seems more likely to me), in which case the will show up as a non-breaking space when it is parsed. Noëlle (talk) 00:40, 8 December 2012 (UTC)
- The title text is copy/pasted from xkcd, where he escapes the ampersand so that the non-breaking space escape will show up in the title text. He might just be toying with those of us who know about the non-breaking space, as most people (the kind of people that would mis-match div and span and change the case of their tags) don't even know what a non-breaking space would be used for.
I wonder if the "answer" in the title text is yet another joke? It goes <A>: Like</A> this — but A used in this way means Anchor, not Answer. Such a line would appear in the browser as "Like this" (with the word Like blue and underlined), making it a clickable "Like" link. 220.127.116.11 (talk) (please sign your comments with ~~~~)
- I think there is another joke hidden there: It goes »<A>: Like </A>this« instead of »: <A>Like</A> this« which turns not only »Like« but also the surrounding whitespace and punctuation into a link/anchor. That points to WYSIWYG HTML editors, as it's easy there to select a little bit more than the intended word when creating a link/marking text as bold, etc. 18.104.22.168 01:03, 8 December 2012 (UTC)
Similarly, it would be nice to address whether you can close a
<div> with a
</span>. Obviously you're not supposed to, but would it work? – Philosopher Let us reason together. 20:57, 7 December 2012 (UTC)
- Opening but not closing a div tag, depends on how a browser's quirks mode interprets that; I'd expect the browser to have everything fall into that div until it encounters a close tag of an element outside (that the div is nested inside). I'd also expect that encountering a close span without having first pushed an open span tag onto the DOM would simply not be recognized as markup and treated as improperly escaped page content. But, I don't write code for any of the major browsers so this is wild speculation. lcarsos_a (talk) 21:24, 7 December 2012 (UTC)
- You can't close a DIV with a SPAN; they're syntactically different and browsers treat them as such. If you try the code above, the major browsers do exactly as Lcarsos suggests with the open DIV (continue until they find a matching /DIV or until /BODY) and completely ignore the /SPAN (Chrome goes so far as to expunge it from the DOM entirely). The DIV behavior exposes a subtler aspect to the comic, actually - because DIV isn't a semantic element, if a /DIV is missing, it can get very, very difficult to track down where the appropriate /DIV is supposed to go, especially when multiple coders are working on a single long (and, in the worst-case scenario, improperly-nested, multi-file) page. Noëlle (talk) 00:39, 8 December 2012 (UTC)