_("Your account"))); dual_begin(array()); print("

" . _("Home") . " / " . _("Your account") . "

\n"); print("

" . _("You have not authenticated yourself to the system yet with your") . " " . _("username") . " " . _("and") . " " . _("password") . ". " . _("You will not be able to use this section of the website without authenticating yourself first. So, please continue and login using the form on the right hand side.") . "

\n"); dual_middle(array()); show_account_details(array()); dual_end(array()); generic_footer(array()); exit; } $volumes_id = array(); $volumes_name = array(); $volumes_mountpoint = array(); $volumes_vg = array(); $volumes_fstype = array(); function volumes_startelement($parser, $name, $attrs) { global $volumes_id, $volumes_name, $volumes_mountpoint, $volumes_vg, $volumes_fstype; if ($name == "VOLUME") { array_push($volumes_id, $attrs["ID"]); array_push($volumes_name, $attrs["NAME"]); array_push($volumes_mountpoint, $attrs["MOUNTPOINT"]); array_push($volumes_vg, $attrs["VG"]); array_push($volumes_fstype, $attrs["FSTYPE"]); } } function volumes_endelement($parser, $name) { } $volumes_parser = xml_parser_create(); xml_set_element_handler($volumes_parser, "volumes_startelement", "volumes_endelement"); $volumes_fp = fopen("/opt/openfiler/etc/volumes.xml", "r"); while ($volumes_data = fread($volumes_fp, 4096)) xml_parse($volumes_parser, $volumes_data, feof($volumes_fp)); fclose($volumes_fp); xml_parser_free($volumes_parser); if ($HTTP_POST_VARS["edit"] == "Change") { if (strlen($HTTP_POST_VARS["newvolumename"]) <= 0) $newvolumename = $volume; $volume = strtolower($volume); $volumesp = popen("/usr/bin/sudo /usr/bin/tee /opt/openfiler/etc/volumes.xml", "w"); fputs($volumesp, "\n"); fputs($volumesp, "\n"); for ($i = 0; $i < count($volumes_id); $i++) if (($volumes_id[$i] != $volume) || ($volumes_vg[$i] != $volume_vg)) fputs($volumesp, "\t\n"); else fputs($volumesp, "\t\n"); fputs($volumesp, "\n"); pclose($volumesp); header("Location: ./volumes.html"); exit; } else if ($HTTP_POST_VARS["edit"] == "Cancel") { header("Location: ./volumes.html"); exit; } if (strlen($HTTP_GET_VARS["volume"]) <= 0) { header("Location: ./volumes.html"); exit; } $volume = strtolower($volume); $vn = 0; while (($vn < count($volumes_id)) && (($volumes_id[$vn] != $volume) || ($volumes_vg[$vn] != $volume_vg))) $vn++; if ($vn >= count($volumes_id)) { header("Location: ./volumes.html"); exit; } generic_header(array("title" => _("Administration Section"))); single_begin(array()); print("

" . _("Home") . " / " . _("Administration Section") . "

\n"); ?>

Welcome Administrator. The following are various system information and preferences, arranged into tabs. Please click on a tab to open up that category.

Edit properties of volume \"" . $volume . "\"\n"); print("
\n"); print("\n"); print("\n"); print("\n"); print("
\n"); print("\n"); print("\n"); print("\t\n"); print("\t\n"); print("\n"); print("\n"); print("\t\n"); print("\t\n"); print("\n"); print("\n"); print("\t\n"); print("\n"); print("
Current volume description" . htmlentities($volumes_name[$vn]) . "
New volume description
 
\n"); print("
\n"); print("
\n"); nested_tab_end(); single_end(array()); generic_footer(array()); ?>