You can easily convert your two dimentional array into one dimentional array using following code
Two Dimentional array example :
Two Dimentional array example :
Array
(
[0] => Array
(
[0] => 70
)
[1] => Array
(
[0] => 67
)
[2] => Array
(
[0] => 75
[1] => 73
[2] => 68
)
[3] => Array
(
[0] => 68
)
[4] => Array
(
[0] => 76
)
)
Please use this function
$oneDimensionalArray = array_map('current', $twoDimensionalArray);
now you will get one dimentional array like below
Array
(
[0] => 70
[1] => 67
[2] => 75
[3] => 73
[4] => 68
[5] => 68
[6] => 76
)
Enjoy ....
No comments:
Post a Comment