I've noticed that some people feel like a vote to close is tantamount to saying "this is a bad question", which (edge cases aside) isn't usually true; when I vote to close, it usually means "this question isn't right for this stack exchange"

For example, consider the question How do I read an attribute of a HTML tag using JavaScript? and the comment thread. It's a fine question: clear, simple, etc. It's just too specific for Stack Overflow (at least according to the current definition of "too localized").

I feel like it would be a good thing if the distinction between "downvote because this is a bad question" and "vote to close because this question isn't right for Stack Overflow" was made clear for the applicable "vote to close" options.

  • And what does the explanation say now that you think should be changed? – Cody Gray Aug 6 '11 at 15:35
  • Off the top of my head, I'm not sure. But if there is some general agreement that this is an issue worth addressing, I could put some thought into it. – David Wolever Aug 6 '11 at 16:15
  • 2
    That question is completely legit. He's asking how to get an attribute value from an HTML tag using JavaScript, and he's posting the specifics of his situation. It should not be closed. – Justin Morgan Aug 6 '11 at 21:36

Sorry, I fail to understand how that question is considered to be "too localized". There are other options to close this question but not "too localized".

Definition for too localized clearly states the following:

This question is unlikely to ever help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet.

I think it is worded very clearly as it could be.

In my opinion, this question it not localized. As a web developer, I have run into scenarios where I might need to grab an ID using JavaScript. I am mostly positive there are lots of other web developers (probably beginners) who might have had a similar question. This might help them.

Probably, the question had been asked earlier because it seems like a commonly asked question. So in that case, the duplicate can be searched and the question can be closed with "exact duplicate" option.

Here are couple of questions that can be used as possible duplicate for How do I read an attribute of a HTML tag using JavaScript? to close the question.

I just searched for "[tag:javascript] getAttribute" and found:

  • I fixed the quotes again. They're in the suggested edit queue now. – BoltClock's a Unicorn Aug 6 '11 at 15:52
  • As I said in the comments, I 100% agree that the spirit of this question is useful. However, given that there is no “general” language used (eg, he uses the attribute name in the title), I think it's very likely that “this question [as it is currently written] is unlikely to ever help any future visitors”… So instead of editing then closing as duplicate (as was suggested) I felt it would be more useful to link to relevant questions and let the OP know that this isn't the kind of question StackOverflow wants. – David Wolever Aug 6 '11 at 16:08
  • HOWEVER, I don't believe your answer here is relevant to the question I asked: it only addresses the one example I linked to, not the “actual” change I'm proposing. – David Wolever Aug 6 '11 at 16:10
  • @David Wolever: Yes, I see your point. However if I may suggest, I would first try to edit the question so that it can be made useful for others. I see that user kiamlaluno just edited the question. This is a question tagged under discussion. Sorry, I am not providing an answer. I just voiced my opinion. – user162697 Aug 6 '11 at 16:11
  • @Siva: Ah, fair enough (re: discussion) :) – David Wolever Aug 6 '11 at 16:17

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .