Name

count

Synopsis

int count(mixed value)

Returns the number of elements in the value; for arrays, this is the number of elements in the array; for any other value, this is 1. If the parameter is a variable and the variable is not set, 0 is returned.

Get Programming PHP now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.