".__('Successfully deleted').""; else $result = "

".__('Not deleted. Error deleting data')."

"; $sql = "DELETE FROM tgraph WHERE id_graph = $id"; if ($res=mysql_query($sql)) $result = "

".__('Successfully deleted')."

"; else $result = "

".__('Not deleted. Error deleting data')."

"; echo $result; } else { pandora_audit("ACL Violation","Trying to delete a graph from access graph builder"); include ("general/noaccess.php"); exit; } } $graphs = get_user_custom_graphs (); if (! empty ($graphs)) { $table->width = '720px'; $tale->class = 'databox_frame'; $table->align = array (); $table->align[0] = 'center'; $table->align[3] = 'right'; $table->align[4] = 'center'; $table->head = array (); $table->head[0] = __('View'); $table->head[1] = __('Graph name'); $table->head[2] = __('Description'); $table->head[3] = __('Number of Graphs'); $table->head[4] = __('Group'); $table->size[0] = '20px'; $table->size[3] = '125px'; $table->size[4] = '50px'; if (give_acl ($config['id_user'], 0, "AW")) { $table->align[5] = 'center'; $table->head[5] = __('Delete'); $table->size[5] = '50px'; } $table->data = array (); foreach ($graphs as $graph) { $data = array (); $data[0] = '' . print_image('images/eye.png', true) . "" . ''; $data[1] = ''.$graph['name'].''; $data[2] = $graph["description"]; $data[3] = $graph["graphs_count"]; $data[4] = print_group_icon($graph['id_group'],true); if (give_acl ($config['id_user'], 0, "AW")) { $data[5] = '' . print_image("images/cross.png", true) . ''; } array_push ($table->data, $data); } print_table ($table); } else { echo "
".__('There are no defined reportings')."
"; } echo '
'; echo '
'; print_submit_button (__('Create graph'), 'create', false, 'class="sub next"'); echo "
"; echo "
"; ?>