. */ include_once __DIR__.'/../../../core.php'; switch ($resource) { case 'tipi_documento': $query = 'SELECT `co_tipidocumento`.`id`, `co_tipidocumento_lang`.`name` AS descrizione FROM `co_tipidocumento` |where| ORDER BY `name` ASC'; $where[] = '`co_tipidocumento`.`enabled` = 1'; $where[] = '`dir`='.$superselect['dir']; foreach ($elements as $element) { $filter[] = '`id`='.prepare($element); } if (!empty($search)) { $search_fields[] = '`name` LIKE '.prepare('%'.$search.'%'); } break; }