> Would you say this is a good moment to pass judgment on your programming abilities ?
Sure. Interestingly </hr> is ignored, but <br></br> is parsed as a block of some kind. I did not know this, so yes, you can judge me for it.
I know you are poking me for what I said about self closing tags, but I stand by it. I've seen a lot of html, and it's one very easy way to find the bad programmers - they all self close <br>. I'm sure there are exceptions, but I have not come across any.
It's a sign of a tutorial programmer (not exactly), maybe, more or a copy/paste programmer, who finds "blocks" of code that work, and just apply it everywhere.
They tend to lack the deep fundamentals of how html works.
> I've seen a lot of html, and it's one very easy way to find the bad programmers - they all self close <br>.
There are a lot of people, including me, who does it out of habit, aesthetic worries, or to make the markup easier to parse for (some) humans. It's a bit like using Egyptian Brackets in JavaScript.
I use self-closing tags for aesthetic reasons, even though I know they aren't HTML. I like the consistency. I suppose I should get with the times, though, if I am to be taken seriously.
Try doing a parser and you will see why self-closing void tags are generally a good idea.
Anyway, I don't understand this discussion at all. I was expecting something a bit better from the HN community. Since when did we start making strong judgments based on purely esthetical things?
An applicant to a position we offered once submitted a code without <head/> nor <body/> tags, and his justification was totally right: the standard doesn't actually require it[1]. So does that make you a bad programmer for using them? Not using them? I believe nobody really care, and I would have to be a really bad person to judge my colleagues based on that.
I've been working with web technologies for years and I happened to like a lot of things about XHTML. I know how the shit works, I just feel its more consistent to close all of your tags. You obviously wouldn't self-close a <div> or a <section> because those tags are supposed to have content!
As an aside, I would argue that <script> should be nullable when it has a src attribute.
It's not parsed as a block of some kind. The standalone <br> is parsed as it should be, without surprises. The closing tag, however, is parsed as another <br> tag. This is usual HTML behaviour, though, and since HTML 5 thoroughly specified.
Sure. Interestingly </hr> is ignored, but <br></br> is parsed as a block of some kind. I did not know this, so yes, you can judge me for it.
I know you are poking me for what I said about self closing tags, but I stand by it. I've seen a lot of html, and it's one very easy way to find the bad programmers - they all self close <br>. I'm sure there are exceptions, but I have not come across any.
It's a sign of a tutorial programmer (not exactly), maybe, more or a copy/paste programmer, who finds "blocks" of code that work, and just apply it everywhere.
They tend to lack the deep fundamentals of how html works.