Ver Mensaje Individual
  #3 (permalink)  
Antiguo 24/02/2021, 18:49
xoceunder
 
Fecha de Ingreso: junio-2012
Ubicación: En el Mundo
Mensajes: 759
Antigüedad: 11 años, 10 meses
Puntos: 10
Respuesta: agregar array nuevo existente

tengo esto

Código PHP:
Ver original
  1. function GetCategories($type = null)
  2. {
  3.     global $ipTV_db;
  4.     if (is_string($type)) {
  5.         $ipTV_db->query('SELECT t1.* FROM `stream_categories` t1 WHERE t1.category_type = \'%s\' GROUP BY t1.id ORDER BY t1.cat_order ASC', $type);
  6.     } else {
  7.         $ipTV_db->query('SELECT t1.* FROM `stream_categories` t1 ORDER BY t1.cat_order ASC');
  8.     }
  9.     return $ipTV_db->num_rows() > 0 ? $ipTV_db->get_rows(true, 'id') : array();
  10. }
  11.  
  12.             case 200:
  13.                 $categories = GetCategories('movie');
  14.                 foreach ($categories as $category) {
  15.                     if (!ipTV_streaming::CategoriesBouq($category['id'], $result['bouquet'])) {
  16.                         continue;
  17.                     }
  18.                     $output[] = array('category_id' => $category['id'], 'category_name' => $category['category_name'], 'parent_id' => 0);
  19.                 }
  20.                 break;

y quiero agregar esto al principio