is_countable()
Check whether count can accept the value.
CKTIS / Knowledge base
Programming syntax, operators and concepts. Find an explanation, explore an example and return to learning.
Check whether count can accept the value.
Identify a floating-point value without numeric coercion.
Check for an actual integer when validating an index.
Identify arrays and objects implementing Traversable before passing data to an iterable parameter.
Test whether a supplied value is exactly null.
Recognize numbers and numeric strings before numeric processing.
Check for any object, including a closure or stdClass.
Test whether an extension handle is currently an open resource.
Accept values of type bool, int, float or string.
Check for a native string even when it is empty, binary or contains digits only.
Invoke a callback while advancing a traversable object.
Count every element in a traversal.
Materialize the traversal in an array.
This alias of implode places a separator only between successive values.
Parse UTF-8 JSON into PHP values.
Serialize a PHP value as UTF-8 JSON.
Check JSON syntax without materializing a PHP value, available since PHP 8.3.
Read the current array key without moving the internal pointer.
Order a map by descending key in place, leaving the value associated with each key.
Put a map in ascending key order in place for a repeatable traversal.
Lowercase the first byte if it is an ASCII uppercase letter and leave the rest unchanged.
Remove matching bytes from the left until the first byte outside the mask.
With one nonempty array, max selects its greatest value rather than its key.
Use mb_strlen to count characters in the specified encoding rather than raw bytes; null selects the internal encoding.