'icon_image', 'class' => 'invert_filter main_menu_icon', 'style' => 'margin-left: 10px', 'content' => ui_print_os_icon($idOS, false, true), ], true ); echo '
'; $table = new stdClass(); $table->width = '100%'; $table->class = 'databox filter-table-adv'; // $table->style[0] = 'width: 15%'; $table->data[0][] = html_print_label_input_block( __('Name'), html_print_input_text('name', $name, __('Name'), 20, 30, true, false, false, '', 'w250px') ); $table->data[0][] = html_print_label_input_block( __('Icon'), html_print_div( [ 'class' => 'flex-row-center', 'content' => implode('', $iconData), ], true ) ); $table->data[1][] = html_print_label_input_block( __('Description'), html_print_textarea('description', 5, 20, $description, '', true, 'w250px') ); html_print_table($table); html_print_input_hidden('id_os', $idOS); html_print_input_hidden('action', $actionHidden); html_print_action_buttons( html_print_submit_button($textButton, 'update_button', false, $classButton, true), ['type' => 'form_action'] ); echo '
'; function get_list_os_icons_dir() { global $config; $return = []; $items = scandir($config['homedir'].'/images/'); foreach ($items as $item) { if (strstr($item, '@os.svg')) { $return[$item] = $item; } } $items2 = scandir($config['homedir'].'/images/os_icons'); foreach ($items2 as $item2) { if (strstr($item2, '_small.png') || strstr($item2, '_small.gif') || strstr($item2, '_small.jpg') ) { continue; } if (strstr($item2, '.png') || strstr($item2, '.gif') || strstr($item2, '.jpg') ) { $return[$item2] = $item2; } } return $return; } ?>