$map['id_group'], 'id_user' => $config['id_user'], 'type' => $map['type'], 'subtype' => $map['subtype'], 'name' => $new_name, 'description' => $map['description'], 'width' => $map['width'], 'height' => $map['height'], 'center_x' => $map['center_x'], 'center_y' => $map['center_y'], 'background' => $map['background'], 'background_options' => $map['background_options'], 'source_period' => $map['source_period'], 'source' => $map['source'], 'source_data' => $map['source_data'], 'generation_method' => $map['generation_method'], 'filter' => $map['filter'])); } return (int)$result; } function maps_delete_map($id) { $where = 'id=' . $id; $result = db_process_sql_delete('tmap', $where); return (int)$result; } function maps_get_count_nodes($id) { $result = db_get_sql("SELECT COUNT(*) FROM titem WHERE id_map = " . $id); return (int)$result; } function maps_update_map ($id, $values) { $where = 'id=' . $id; $result = db_process_sql_update('tmap', $values, $where); return (int)$result; } function maps_is_networkmap($id) { $return = db_get_value('type', 'tmap', 'id', $id); if ($return === false) return false; if ($return == MAP_TYPE_NETWORKMAP) return true; else return false; } function maps_is_visualmap($id) { $return = db_get_value('type', 'tmap', 'id', $id); if ($return === false) { return false; } if ($return == MAP_TYPE_VISUALMAP) { return true; } else { return false; } } function maps_show($id) { if (maps_is_networkmap($id)) { require_once("include/functions_networkmaps.php"); networkmaps_show($id); } else { //TODO VISUAL } } ?>