create and add items to an array in php code example
Example 1: array_push
$array[$key] = $value;
// or
$array[] = $value;
// or
array_push($array, [ mixed $... ]);
Example 2: php array push
array_push ( array &$array [, mixed $... ] ) : int
or
$array[] = $var;