Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Buyer beware: PHP documentation is not always as extensive as is boasted and the user comments often times are very dangerously wrong. For an example of this see the comments to json_encode where many wrong PHP implementations are suggested (they don't take care of escaping non-ASCII data), or the read/write/socket functions where bizarre timeout behavior is suggested, or the microtime and usleep functions where even more bizarre things are suggested.


I fully agree. For instance, PHP implements it's own round function. Now there very well may be a good reason they don't just use/implement the C99 round - but one can at least expect it not to change. This isn't true, in some version (I forget which), they changed their implementation and that caused all sorts of headaches to us and our users that depend on these numbers.

Moral of the story? Don't use PHP for stats.


As with most comments on the internet, you have to be careful not to take it all as stated fact, they are moderated which is good but I doubt they go into the implications of code snippets on edge cases when approving.

I haven't found anything misleading enough in the actual documentation to remember.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: