posted 15 years ago
I was editing some code today and saw what looked like an error to me, but nothing was broken on the code I was looking at it, so I was prompted to look it up. And indeed, in PHP:
“Having a trailing comma after the last defined array entry, while unusual, is a valid syntax.”
So sayeth the documentation for PHP: array
If it says it in there, it must be true.
So this is legal php:
… which, as I said, looks so bizarre to me.