public function ShowAllPrimaryFolders() { $box_folders = parent::get_all_folders(); $folders = array(); if (isset($box_folders['type'])) { if ($this->Get_type($box_folders['type']) == 0) { $items = $box_folders['item_collection']['entries']; foreach ($items as $values) { array_push($folders, array("name" => $values['name'], "id" => $values['id'], "type" => $values['type'])); } } } return $folders; }