I have an array that outputs the following:
Array
(
[0] => Array
(
[0] => wordpress
)
[1] => Array
(
[0] => wordpress
[1] => forms
)
[2] => Array
(
[0] => wordpress
[1] => galleries
)
[3] => Array
(
[0] => wordpress
[1] => ecommerce
)
[4] => Array
(
[0] => wordpress
[1] => ecommerce
[2] => wp-e-commerce
)
)
How would i go about adding an item into the [0] => Array?
This is the way i have created my array:
$cats = array();
foreach($items as $x=> $item) {
$ex = explode("/",$item['path']);
$cats[] = explode("/",$item['path']);
echo $item['name'].' - '. $item['path'];
echo "<br>";
}
print_r($cats);
Any help would be greatly appreciated!
Thanks