I have a variable like so:
$array = array();
$stock = 1500;
How can extract this number and add each number starting from 1 into $array
.
For example:
$array = [1, 2, 3, 4, 5, 6, ..., 1500];
I have a variable like so:
$array = array();
$stock = 1500;
How can extract this number and add each number starting from 1 into $array
.
For example:
$array = [1, 2, 3, 4, 5, 6, ..., 1500];