4 ms·
You're probably thinking of in_array() and strpos(). Yeah, the names themselves are confusing, not just the order of arguments. I wish PHP was fully object-ori
by kijin 8y ago
You're probably thinking of in_array() and strpos(). Yeah, the names themselves are confusing, not just the order of arguments.
I wish PHP was fully object-oriented so you could call a method on any array, string, or number like in JavaScript. $haystack->contains($needle) is so much more consistent! That would eliminate the need for most of those confusing global functions, which can then be safely deprecated.