The most recent example, in my case, was:
http://stackoverflow.com/questions/10166086/good-examples-of...
"Can anybody recommend some [PHP] programs for me to look at, that promote best practises, but are simple enough for me to understand?"
"closed as not a real question; It's difficult to tell what is being asked here. [no it's not] This question is ambiguous [nope], vague [no], incomplete [er, no], overly broad [no], or rhetorical [still no] and cannot be reasonably answered in its current form [no again]. See the FAQ for guidance on how to improve it [mmm, passive-agression]."
... er, WTF guys? Given the minefield that is trying to write good PHP, it's a very good question. A couple of good answers had, I note, already been given, which puts the lie to the mods' reasoning -- but they killed it off anyway, even though it was showing promise? Really?
Reeks of power-tripping or jobsworthy moderation to me.
Does stackexchange forbid questions where there's an element of opinion, because the system's set up only for questions with "one right answer"? That seems awfully restrictive in the name of a system limitation.
Especially as, as 4ad observed, the asker chooses an incorrect answer annoyingly often -- so the "best answer" isn't always actually the best. As such, it's advisable to at least flick through the other answers anyway, despite this rule.
That's not the problem on the sample question.
I see that as the issue - that there has to be one answer. It's a site that promotes the same issue that plagues reddit, the hunger for karma.
what are the best practices when it comes to PHP?
And are there recommended ways of tackling certain task?
And these are, I believe, ambiguous, vague and overly broad (not to mention subjective).
Also the third question, the one you quote, is actually a yes/no question that would be pointless to answer. So, assuming that's not the real question... what is? I believe it IS difficult to tell what is being asked here.
StackExchange is just not meant for discussion, I think. At last not as it is right now.
And the existence of the other questions is beside the point -- the title of the question is "Good examples of PHP code for an intermediate PHPer?", the body is merely exposition. I only quoted the equivalent question from the body because it had better grammar than the title.
It also seems like they have a lot of help vampires as I see many questions where the correct answer doesn't have even a single upvote.
At Stack Exchange, we do science in the small. Bite-size, fun-size units of science that shouldn't feel like work, but collectively build something amazing for a community of people who love a particular topic.
Just because echo doesn't read from files doesn't mean it's useless. If you need to read from files you just use cat instead. Sure, you can coerce both to do the other's job, but it'll be messy and only work half the time and other people will be annoyed at you. Different solutions for different needs.
That said the community+software is good at what it does. I can be sad it's intolerant of lists without needing to disparage it further.
Besides in a Q&A network, a "list question" has "list answers" where every "answer" is a "list", rather than an item of that list. Even that doesn't really work because that's not historically the way the site is actually used.
See also the following for the rationale:
http://blog.stackoverflow.com/2011/01/real-questions-have-an...
No knock on SE. Quite the opposite.
But I frequently have questions that aren't SE style questions, and I wish I knew where to take them for such intelligent and informed responses.
I really strongly believe that it's an either/or proposition, you either get discussion or you get quality answers to questions. Discussion "sucks the air out", so to speak.
And since there are already so many places for discussion on the internet, it's better for us to focus on Q&A.
StackExchange is a Q&A community website. Although sometimes discussion would be appreciated, it is not what it was meant for. And by all means, if you find an accepted answer to be wrong, downvote and comment it! The whole point of StackExchange websites is to rate questions and answers!
When asking questions, I try to make them good enough so that other people will find them useful in the future, and it's great when I get a like-minded answer. Some examples:
http://stackoverflow.com/questions/9708945/how-to-embed-a-ne...
http://stackoverflow.com/questions/10252440/changing-the-det...
Still, I think StackOverflow could be taken up a notch to allow more collaboration and organization. Also, wouldn't it be great to be able to provide runnable source code in some sort of git archive? For some languages like Javascript the code in the questions/answers could be in something like http://jsfiddle.net
Ideally, a group of people could pick any topic and essentially write several books (beginner and advanced) by asking lots of questions. At least that was my initial belief. Say, for example, you wanted to learn elisp, and you typed: "Hello world in emacs", well I've got that answered:
http://stackoverflow.com/questions/2170528/writing-hello-wor...
I didn't quite get a book with Elisp, but I did throw down quite a few breadcrumbs:
CGI: http://stackoverflow.com/questions/1532311/cgi-programming-i...
AWK Example: http://stackoverflow.com/questions/2260294/awk-print-2-1-in-...
Extract URLs: http://stackoverflow.com/questions/1642184/extracting-urls-f...
Parse CSV/Gen HTML: http://stackoverflow.com/questions/1541682/lisp-script-to-pa...
Wrap Selection like Textmate: http://stackoverflow.com/questions/1558178/wrap-selection-in...
MySql (Unanswered): http://stackoverflow.com/questions/1532365/mysql-queries-fro...
Generate a Quiz: http://stackoverflow.com/questions/2264286/generating-a-quiz...
Open Browser: http://stackoverflow.com/questions/1532365/mysql-queries-fro...
Generate a Quiz (Common Lisp): http://stackoverflow.com/questions/2264267/generating-a-quiz...
http://stackoverflow.com/questions/2115341/sorting-buffer-li...
http://stackoverflow.com/questions/2358604/convert-decimal-h...
http://stackoverflow.com/questions/2170120/operating-on-mult...
Can a dog have the Bhudda nature - is a good question but it's not really a problem.
How do I connect to a wifi network without an SSID in Ubuntu is a problem - even if it is a less good question