I wouldn't say that anyone has the impression that "all PHP programmers are stupid." Rather, it's more that PHP, on top of attracting O(N) competent developers like any other language, also attracts O(k >> N) marginal developers who barely know enough to get off the ground, and couldn't really manage to code in any other language. When you randomly select a "representative" PHP coder (such as by listing "knows PHP" as a criterion for resume submissions), you get a marginal one.
Stupid was a bit too strong, but, I stand by what I said based on my experience. Articles like these exist partly because of the belief that PHP programmers in general are not competent. You do not hear such frequent rumbling on Python and it's practitioners. One could apply the same O(N)and O(k>>N) logic there as IMO, Python is not harder to learn/program in compared with PHP.