diff options
author | Renato Botelho <renato.botelho@bluepex.com> | 2010-06-30 09:30:01 -0300 |
---|---|---|
committer | Renato Botelho <renato.botelho@bluepex.com> | 2010-06-30 09:30:01 -0300 |
commit | 0b3abd3b5639676b27a78e651c6753c38e6c8bbe (patch) | |
tree | e727ffd9d36f8d868a5d080213fddcf79ef7f5b6 /usr/local/www | |
parent | a5e9c28444e3dc6a3c1668719786c3a389ba652e (diff) | |
download | pfsense-0b3abd3b5639676b27a78e651c6753c38e6c8bbe.zip pfsense-0b3abd3b5639676b27a78e651c6753c38e6c8bbe.tar.gz |
Reset diag_ files
Diffstat (limited to 'usr/local/www')
36 files changed, 576 insertions, 576 deletions
diff --git a/usr/local/www/diag_arp.php b/usr/local/www/diag_arp.php index 3aff783..4a6e92c 100755 --- a/usr/local/www/diag_arp.php +++ b/usr/local/www/diag_arp.php @@ -205,15 +205,15 @@ if(count($pools) > 0) { // Put this in an easy to use form $dhcpmac = array(); $dhcpip = array(); - + foreach ($leases as $value) { - $dhcpmac[$value['mac']] = $value['hostname']; - $dhcpip[$value['ip']] = $value['hostname']; + $dhcpmac[$value['mac']] = $value['hostname']; + $dhcpip[$value['ip']] = $value['hostname']; } exec("/usr/sbin/arp -an",$rawdata); -$i = 0; +$i = 0; /* if list */ $ifdescrs = get_configured_interface_with_descr(); @@ -225,7 +225,7 @@ foreach ($ifdescrs as $key =>$interface) { $data = array(); foreach ($rawdata as $line) { $elements = explode(' ',$line); - + if ($elements[3] != "(incomplete)") { $arpent = array(); $arpent['ip'] = trim(str_replace(array('(',')'),'',$elements[1])); @@ -238,28 +238,28 @@ foreach ($rawdata as $line) { function getHostName($mac,$ip) { global $dhcpmac, $dhcpip; - + if ($dhcpmac[$mac]) return $dhcpmac[$mac]; else if ($dhcpip[$ip]) return $dhcpip[$ip]; else if(gethostbyaddr($ip) <> "" and gethostbyaddr($ip) <> $ip) return gethostbyaddr($ip); - else - return ""; + else + return ""; } -$pgtitle = array(gettext("Diagnostics"),gettext("ARP Table")); +$pgtitle = array("Diagnostics","ARP Table"); include("head.inc"); ?> <body link="#000000" vlink="#000000" alink="#000000"> - + <?php include("fbegin.inc"); ?> <div id="loading"> - <img src="/themes/{$g['theme']}/images/misc/loader.gif"><?= gettext("Loading, please wait..."); ?> + <img src="/themes/{$g['theme']}/images/misc/loader.gif"> Loading, please wait... <p/> </div> @@ -276,7 +276,7 @@ foreach ($data as &$entry) { $dns = trim(getHostName($entry['mac'], $entry['ip'])); if(trim($dns)) $entry['dnsresolve'] = "$dns"; - else + else $entry['dnsresolve'] = "Z_ "; } @@ -289,10 +289,10 @@ $data = msort($data, "dnsresolve"); <td> <table class="tabcont sortable" width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> - <td class="listhdrr"><?= gettext("IP address"); ?></td> - <td class="listhdrr"><?= gettext("MAC address"); ?></td> - <td class="listhdrr"><?= gettext("Hostname"); ?></td> - <td class="listhdr"><?= gettext("Interface"); ?></td> + <td class="listhdrr">IP address</td> + <td class="listhdrr">MAC address</td> + <td class="listhdrr">Hostname</td> + <td class="listhdr">Interface</td> <td class="list"></td> </tr> <?php foreach ($data as $entry): ?> diff --git a/usr/local/www/diag_authentication.php b/usr/local/www/diag_authentication.php index 91874d4..f6ed771 100755 --- a/usr/local/www/diag_authentication.php +++ b/usr/local/www/diag_authentication.php @@ -49,30 +49,30 @@ if ($_POST) { $authcfg = auth_get_authserver($_POST['authmode']); if (!$authcfg) - $input_errors[] = $_POST['authmode'] . " " . gettext("is not a valid authentication server"); + $input_errors[] = "{$_POST['authmode']} is not a valid authentication server "; if (empty($_POST['username']) || empty($_POST['password'])) - $input_errors[] = gettext("A username and password must be specified."); + $input_errors[] = "A username and password must be specified."; if (!$input_errors) { if (authenticate_user($_POST['username'], $_POST['password'], $authcfg)) { - $savemsg = gettext("User") . ": " . $_POST['username'] . " " . gettext("authenticated sucessfully."); + $savemsg = "User: {$_POST['username']} authenticated sucessfully."; $groups = getUserGroups($_POST['username'], $authcfg); - $savemsg .= "<br />" + gettext("This user is member of this groups") + ": <br />"; + $savemsg .= "<br />This user is member of this groups: <br />"; foreach ($groups as $group) $savemsg .= "{$group} "; } else { - $input_errors[] = gettext("Authentication failed."); + $input_errors[] = "Authentication failed."; } } } -$pgtitle = array(gettext("Diagnostics"),gettext("Authentication")); +$pgtitle = array("Diagnostics","Authentication"); include("head.inc"); ?> <body link="#000000" vlink="#000000" alink="#000000"> - + <?php include("fbegin.inc"); ?> <?php if ($input_errors) print_input_errors($input_errors);?> <?php if ($savemsg) print_info_box($savemsg);?> @@ -87,7 +87,7 @@ include("head.inc"); <form id="iform" name="iform" action="diag_authentication.php" method="post"> <table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="6"> <tr> - <td width="22%" valign="top" class="vncell"><?=gettext("Authentication Server"); ?></td> + <td width="22%" valign="top" class="vncell">Authentication Server</td> <td width="78%" class="vtable"> <select name='authmode' id='authmode' class="formselect" > <?php @@ -103,13 +103,13 @@ include("head.inc"); </td> </tr> <tr> - <td width="22%" valign="top" class="vncell"><?=gettext("Username"); ?></td> + <td width="22%" valign="top" class="vncell">Username</td> <td width="78%" class="vtable"> <input class="formfld unknown" size='20' id='username' name='username' value='<?=$pconfig['username'];?>' /> </td> </tr> <tr> - <td width="22%" valign="top" class="vncell"><?=gettext("Password"); ?></td> + <td width="22%" valign="top" class="vncell">Password</td> <td width="78%" class="vtable"> <input class="formfld pwd" type='password' size='20' id='password' name='password' value='<?=$pconfig['password'];?>' /> </td> diff --git a/usr/local/www/diag_backup.php b/usr/local/www/diag_backup.php index 6ce7b8d..e2cbacb 100755 --- a/usr/local/www/diag_backup.php +++ b/usr/local/www/diag_backup.php @@ -60,7 +60,7 @@ function add_base_packages_menu_items() { $modified_config = false; foreach($base_packages as $bp) { $basepkg_path = "/usr/local/pkg/{$bp}"; - $tmpinfo = pathinfo($basepkg_path, PATHINFO_EXTENSION); + $tmpinfo = pathinfo($basepkg_path, PATHINFO_EXTENSION); if($tmpinfo['extension'] == "xml" && file_exists($basepkg_path)) { $pkg_config = parse_xml_config_pkg($basepkg_path, "packagegui"); if($pkg_config['menu'] != "") { @@ -80,7 +80,7 @@ function add_base_packages_menu_items() { } } if($modified_config) { - write_confg(gettext("Restored base_package menus after configuration restore.")); + write_confg("Restored base_package menus after configuration restore."); $config = parse_config(true); } } @@ -98,28 +98,28 @@ function check_and_returnif_section_exists($section) { function spit_out_select_items($area, $showall) { global $config; - - $areas = array("aliases" => gettext("Aliases"), - "captiveportal" => gettext("Captive Portal"), - "voucher" => gettext("Captive Portal Vouchers"), - "dnsmasq" => gettext("DNS Forwarder"), - "dhcpd" => gettext("DHCP Server"), - "filter" => gettext("Firewall Rules"), - "interfaces" => gettext("Interfaces"), - "ipsec" => gettext("IPSEC"), - "nat" => gettext("NAT"), - "ovpn" => gettext("OpenVPN"), - "installedpackages" => gettext("Package Manager"), - "pptpd" => gettext("PPTP Server"), - "cron" => gettext("Scheduled Tasks"), - "syslog" => gettext("Syslog"), - "system" => gettext("System"), - "staticroutes" => gettext("Static routes"), - "sysctl" => gettext("System tunables"), - "snmpd" => gettext("SNMP Server"), - "shaper" => gettext("Traffic Shaper"), - "vlans" => gettext("VLANS"), - "wol" => gettext("Wake on LAN") + + $areas = array("aliases" => "Aliases", + "captiveportal" => "Captive Portal", + "voucher" => "Captive Portal Vouchers", + "dnsmasq" => "DNS Forwarder", + "dhcpd" => "DHCP Server", + "filter" => "Firewall Rules", + "interfaces" => "Interfaces", + "ipsec" => "IPSEC", + "nat" => "NAT", + "ovpn" => "OpenVPN", + "installedpackages" => "Package Manager", + "pptpd" => "PPTP Server", + "cron" => "Scheduled Tasks", + "syslog" => "Syslog", + "system" => "System", + "staticroutes" => "Static routes", + "sysctl" => "System tunables", + "snmpd" => "SNMP Server", + "shaper" => "Traffic Shaper", + "vlans" => "VLANS", + "wol" => "Wake on LAN" ); $select = "<select name=\"{$area}\" id=\"{$aread}\" "; @@ -128,16 +128,16 @@ function spit_out_select_items($area, $showall) { $select .= " >\n"; $select .= "<option VALUE=\"\">ALL</option>"; - if($showall == true) + if($showall == true) foreach($areas as $area => $areaname) $select .= "<option value='{$area}'>{$areaname}</option>\n"; - else + else foreach($areas as $area => $areaname) if(check_and_returnif_section_exists($area) == true) $select .= "<option value='{$area}'>{$areaname}</option>\n"; $select .= "</select>\n"; - + echo $select; } @@ -153,13 +153,13 @@ if ($_POST['apply']) { if ($_POST) { unset($input_errors); - if (stristr($_POST['Submit'], gettext("Restore configuration"))) + if (stristr($_POST['Submit'], "Restore configuration")) $mode = "restore"; - else if (stristr($_POST['Submit'], gettext("Reinstall"))) + else if (stristr($_POST['Submit'], "Reinstall")) $mode = "reinstallpackages"; - else if (stristr($_POST['Submit'], gettext("Download"))) + else if (stristr($_POST['Submit'], "Download")) $mode = "download"; - else if (stristr($_POST['Submit'], gettext("Restore version"))) + else if (stristr($_POST['Submit'], "Restore version")) $mode = "restore_ver"; if ($_POST["nopackages"] <> "") @@ -174,9 +174,9 @@ if ($_POST) { if ($_POST['encrypt']) { if(!$_POST['encrypt_password'] || !$_POST['encrypt_passconf']) - $input_errors[] = gettext("You must supply and confirm the password for encryption."); + $input_errors[] = "You must supply and confirm the password for encryption."; if($_POST['encrypt_password'] != $_POST['encrypt_passconf']) - $input_errors[] = gettext("The supplied 'Password' and 'Confirm' field values must match."); + $input_errors[] = "The supplied 'Password' and 'Confirm' field values must match."; } if (!$input_errors) { @@ -199,7 +199,7 @@ if ($_POST) { $sfn = "{$g['tmp_path']}/config.xml.nopkg"; file_put_contents($sfn, $data); exec("sed '/<installedpackages>/,/<\/installedpackages>/d' {$sfn} > {$sfn}-new"); - $data = file_get_contents($sfn . "-new"); + $data = file_get_contents($sfn . "-new"); } else { if(!$_POST['backuparea']) { /* backup entire configuration */ @@ -218,7 +218,7 @@ if ($_POST) { tagfile_reformat($data, $data, "config.xml"); } - /* + /* * Backup RRD Data */ if(!$_POST['donotbackuprrd']) { @@ -238,7 +238,7 @@ if ($_POST) { $data .= "\t</rrddata>\n"; $data .= "</pfsense>\n"; } - + $size = strlen($data); header("Content-Type: application/octet-stream"); header("Content-Disposition: attachment; filename={$name}"); @@ -260,9 +260,9 @@ if ($_POST) { if ($_POST['decrypt']) { if(!$_POST['decrypt_password'] || !$_POST['decrypt_passconf']) - $input_errors[] = gettext("You must supply and confirm the password for decryption."); + $input_errors[] = "You must supply and confirm the password for decryption."; if($_POST['decrypt_password'] != $_POST['decrypt_passconf']) - $input_errors[] = gettext("The supplied 'Password' and 'Confirm' field values must match."); + $input_errors[] = "The supplied 'Password' and 'Confirm' field values must match."; } if (!$input_errors) { @@ -272,20 +272,20 @@ if ($_POST) { /* read the file contents */ $data = file_get_contents($_FILES['conffile']['tmp_name']); if(!$data) { - log_error(gettext("Warning, could not read file") . " " . $_FILES['conffile']['tmp_name']); + log_error("Warning, could not read file " . $_FILES['conffile']['tmp_name']); return 1; } if ($_POST['decrypt']) { if (!tagfile_deformat($data, $data, "config.xml")) { - $input_errors[] = gettext("The uploaded file does not appear to contain an encrypted pfsense configuration."); + $input_errors[] = "The uploaded file does not appear to contain an encrypted pfsense configuration."; return 1; } $data = decrypt_data($data, $_POST['decrypt_password']); } if(stristr($data, "<m0n0wall>")) { - log_error(gettext("Upgrading m0n0wall configuration to pfsense.")); + log_error("Upgrading m0n0wall configuration to pfsense."); /* m0n0wall was found in config. convert it. */ $data = str_replace("m0n0wall", "pfsense", $data); $m0n0wall_upgrade = true; @@ -293,15 +293,15 @@ if ($_POST) { if($_POST['restorearea']) { /* restore a specific area of the configuration */ if(!stristr($data, $_POST['restorearea'])) { - $input_errors[] = gettext("You have selected to restore an area but we could not locate the correct xml tag."); + $input_errors[] = "You have selected to restore an area but we could not locate the correct xml tag."; } else { restore_config_section($_POST['restorearea'], $data); filter_configure(); - $savemsg = gettext("The configuration area has been restored. You may need to reboot the firewall."); + $savemsg = "The configuration area has been restored. You may need to reboot the firewall."; } } else { if(!stristr($data, "<" . $g['xml_rootobj'] . ">")) { - $input_errors[] = gettext("You have selected to restore the full configuration but we could not locate a") . " " . $g['xml_rootobj'] . " " . gettext("tag."); + $input_errors[] = "You have selected to restore the full configuration but we could not locate a " . $g['xml_rootobj'] . " tag."; } else { /* restore the entire configuration */ file_put_contents($_FILES['conffile']['tmp_name'], $data); @@ -370,7 +370,7 @@ if ($_POST) { } unlink_if_exists("{$g['tmp_path']}/config.cache"); // Reset configuration version to something low - // in order to force the config upgrade code to + // in order to force the config upgrade code to // run through with all steps that are required. $config['system']['version'] = "1.0"; // Deal with descriptions longer than 63 characters @@ -432,10 +432,10 @@ if ($_POST) { } $config['diag']['ipv6nat'] = true; write_config(); - add_base_packages_menu_items(); + add_base_packages_menu_items(); convert_config(); conf_mount_ro(); - $savemsg = gettext("The m0n0wall configuration has been restored and upgraded to pfSense."); + $savemsg = "The m0n0wall configuration has been restored and upgraded to pfSense."; mark_subsystem_dirty("restore"); } if(isset($config['captiveportal']['enable'])) { @@ -451,12 +451,12 @@ if ($_POST) { exit; } } else { - $input_errors[] = gettext("The configuration could not be restored."); + $input_errors[] = "The configuration could not be restored."; } } } } else { - $input_errors[] = gettext("The configuration could not be restored (file upload error)."); + $input_errors[] = "The configuration could not be restored (file upload error)."; } } } @@ -466,16 +466,16 @@ if ($_POST) { header("Location: pkg_mgr_install.php?mode=reinstallall"); exit; } else if ($mode == "restore_ver") { - $input_errors[] = gettext("XXX - this feature may hose your config (do NOT backrev configs!) - billm"); + $input_errors[] = "XXX - this feature may hose your config (do NOT backrev configs!) - billm"; if ($ver2restore <> "") { $conf_file = "{$g['cf_conf_path']}/bak/config-" . strtotime($ver2restore) . ".xml"; if (config_install($conf_file) == 0) { mark_subsystem_dirty("restore"); } else { - $input_errors[] = gettext("The configuration could not be restored."); + $input_errors[] = "The configuration could not be restored."; } } else { - $input_errors[] = gettext("No version selected."); + $input_errors[] = "No version selected."; } } } @@ -486,7 +486,7 @@ $id = rand() . '.' . time(); $mth = ini_get('upload_progress_meter.store_method'); $dir = ini_get('upload_progress_meter.file.filename_template'); -$pgtitle = array(gettext("Diagnostics"),gettext("Backup/restore")); +$pgtitle = array("Diagnostics","Backup/restore"); include("head.inc"); ?> @@ -527,7 +527,7 @@ function backuparea_change(obj) { <?php if (is_subsystem_dirty('restore')): ?><p> <form action="reboot.php" method="post"> <input name="Submit" type="hidden" value=" Yes "> -<?php print_info_box(gettext("The firewall configuration has been changed.") . "<br/>" . gettext("The firewall is now rebooting."));?><br> +<?php print_info_box("The firewall configuration has been changed.<br/>The firewall is now rebooting.");?><br> </form> <?php endif; ?> <form action="diag_backup.php" method="post" name="iform" enctype="multipart/form-data"> @@ -536,8 +536,8 @@ function backuparea_change(obj) { <td> <?php $tab_array = array(); - $tab_array[0] = array(gettext("Config History"), false, "diag_confbak.php"); - $tab_array[1] = array(gettext("Backup/Restore"), true, "diag_backup.php"); + $tab_array[0] = array("Config History", false, "diag_confbak.php"); + $tab_array[1] = array("Backup/Restore", true, "diag_backup.php"); display_top_tabs($tab_array); ?> </td> @@ -547,19 +547,19 @@ function backuparea_change(obj) { <div id="mainarea"> <table class="tabcont" align="center" width="100%" border="0" cellpadding="6" cellspacing="0"> <tr> - <td colspan="2" class="listtopic"><?=gettext("Backup configuration"); ?></td> + <td colspan="2" class="listtopic">Backup configuration</td> </tr> <tr> <td width="22%" valign="baseline" class="vncell"> </td> <td width="78%" class="vtable"> - <p><?=gettext("Click this button to download the system configuration in XML format."); ?><br /><br /> <?=gettext("Backup area:"); ?> <?php spit_out_select_items("backuparea", false); ?></p> + <p>Click this button to download the system configuration in XML format.<br /><br /> Backup area: <?php spit_out_select_items("backuparea", false); ?></p> <table> <tr> <td> <input name="nopackages" type="checkbox" class="formcheckbox" id="nopackages"> </td> <td> - <span class="vexpl"><?=gettext("Do not backup package information."); ?></span> + <span class="vexpl">Do not backup package information.</span> </td> </tr> </table> @@ -569,7 +569,7 @@ function backuparea_change(obj) { <input name="encrypt" type="checkbox" class="formcheckbox" id="nopackages" onClick="encrypt_change()"> </td> <td> - <span class="vexpl"><?=gettext("Encrypt this configuration file."); ?></span> + <span class="vexpl">Encrypt this configuration file.</span> </td> </tr> <tr> @@ -577,14 +577,14 @@ function backuparea_change(obj) { <input name="donotbackuprrd" type="checkbox" class="formcheckbox" id="dotnotbackuprrd" checked> </td> <td> - <span class="vexpl"><?=gettext("Do not backup RRD data (NOTE: RRD Data can consume 4+ megabytes of config.xml space!)"); ?></span> + <span class="vexpl">Do not backup RRD data (NOTE: RRD Data can consume 4+ megabytes of config.xml space!)</span> </td> </tr> </table> <table id="encrypt_opts"> <tr> <td> - <span class="vexpl"><?=gettext("Password"); ?> :</span> + <span class="vexpl">Password :</span> </td> <td> <input name="encrypt_password" type="password" class="formfld pwd" size="20" value="" /> @@ -592,7 +592,7 @@ function backuparea_change(obj) { </tr> <tr> <td> - <span class="vexpl"><?=gettext("confirm"); ?> :</span> + <span class="vexpl">confirm :</span> </td> <td> <input name="encrypt_passconf" type="password" class="formfld pwd" size="20" value="" /> @@ -606,12 +606,12 @@ function backuparea_change(obj) { <td colspan="2" class="list" height="12"> </td> </tr> <tr> - <td colspan="2" class="listtopic"><?=gettext("Restore configuration"); ?></td> + <td colspan="2" class="listtopic">Restore configuration</td> </tr> <tr> <td width="22%" valign="baseline" class="vncell"> </td> <td width="78%" class="vtable"> - <?=gettext("Open a"); ?> <?=$g['[product_name']?> <?=gettext("configuration XML file and click the button below to restore the configuration."); ?> <br /><br /> <?=gettext("Restore area:"); ?> <?php spit_out_select_items("restorearea", true); ?> + Open a <?=$g['[product_name']?> configuration XML file and click the button below to restore the configuration. <br /><br /> Restore area: <?php spit_out_select_items("restorearea", true); ?> <p><input name="conffile" type="file" class="formfld unknown" id="conffile" size="40"></p> <table> <tr> @@ -619,14 +619,14 @@ function backuparea_change(obj) { <input name="decrypt" type="checkbox" class="formcheckbox" id="nopackages" onClick="decrypt_change()"> </td> <td> - <span class="vexpl"><?=gettext("Configuration file is encrypted."); ?></span> + <span class="vexpl">Configuration file is encrypted.</span> </td> </tr> </table> <table id="decrypt_opts"> <tr> <td> - <span class="vexpl"><?=gettext("Password :"); ?></span> + <span class="vexpl">Password :</span> </td> <td> <input name="decrypt_password" type="password" class="formfld pwd" size="20" value="" /> @@ -634,7 +634,7 @@ function backuparea_change(obj) { </tr> <tr> <td> - <span class="vexpl"><?=gettext("confirm :"); ?></span> + <span class="vexpl">confirm :</span> </td> <td> <input name="decrypt_passconf" type="password" class="formfld pwd" size="20" value="" /> @@ -642,7 +642,7 @@ function backuparea_change(obj) { </tr> </table> <p><input name="Submit" type="submit" class="formbtn" id="restore" value="Restore configuration"></p> - <p><strong><span class="red">Note:</span></strong><br /><?=gettext("The firewall will reboot after restoring the configuration."); ?><br /></p> + <p><strong><span class="red">Note:</span></strong><br />The firewall will reboot after restoring the configuration.<br /></p> </td> </tr> <?php if($config['installedpackages']['package'] != "") { ?> @@ -650,12 +650,12 @@ function backuparea_change(obj) { <td colspan="2" class="list" height="12"> </td> </tr> <tr> - <td colspan="2" class="listtopic"><?=gettext("Reinstall packages"); ?></td> + <td colspan="2" class="listtopic">Reinstall packages</td> </tr> <tr> <td width="22%" valign="baseline" class="vncell"> </td> <td width="78%" class="vtable"> - <p><?=gettext("Click this button to reinstall all system packages. This may take a while."); ?> <br /><br /> + <p>Click this button to reinstall all system packages. This may take a while. <br /><br /> <input name="Submit" type="submit" class="formbtn" id="reinstallpackages" value="Reinstall packages"> </td> </tr> diff --git a/usr/local/www/diag_confbak.php b/usr/local/www/diag_confbak.php index 393f771..5d0458b 100755 --- a/usr/local/www/diag_confbak.php +++ b/usr/local/www/diag_confbak.php @@ -28,7 +28,7 @@ POSSIBILITY OF SUCH DAMAGE. */ -/* +/* pfSense_MODULE: config */ @@ -45,10 +45,9 @@ if($_GET['newver'] != "") { conf_mount_rw(); $confvers = unserialize(file_get_contents($g['cf_conf_path'] . '/backup/backup.cache')); if(config_restore($g['conf_path'] . '/backup/config-' . $_GET['newver'] . '.xml') == 0) - - $savemsg = sprintf(gettext("Successfully reverted to timestamp %s with description \"%s\"."), date(gettext("n/j/y H:i:s"), $_GET['newver']), $confvers[$_GET['newver']]['description']); + $savemsg = "Successfully reverted to timestamp " . date("n/j/y H:i:s", $_GET['newver']) . " with description \"" . $confvers[$_GET['newver']]['description'] . "\"."; else - $savemsg = gettext("Unable to revert to the selected configuration."); + $savemsg = "Unable to revert to the selected configuration."; conf_mount_ro(); } @@ -56,7 +55,7 @@ if($_GET['rmver'] != "") { conf_mount_rw(); $confvers = unserialize(file_get_contents($g['cf_conf_path'] . '/backup/backup.cache')); unlink_if_exists($g['conf_path'] . '/backup/config-' . $_GET['rmver'] . '.xml'); - $savemsg = sprintf(gettext("Deleted backup with timestamp %s and description \"%s\"."), date(gettext("n/j/y H:i:s"), $_GET['rmver']),$confvers[$_GET['rmver']]['description']); + $savemsg = "Deleted backup with timestamp " . date("n/j/y H:i:s", $_GET['rmver']) . " and description \"" . $confvers[$_GET['rmver']]['description'] . "\"."; conf_mount_ro(); } @@ -95,7 +94,7 @@ cleanup_backupcache(); $confvers = get_backups(); unset($confvers['versions']); -$pgtitle = array(gettext("Diagnostics"),gettext("Configuration History")); +$pgtitle = array("Diagnostics","Configuration History"); include("head.inc"); ?> @@ -108,7 +107,7 @@ include("head.inc"); ?> <? if ($diff) { ?> <table align="center" valign="middle" width="100%" border="0" cellspacing="0" style="padding-top: 4px; padding-bottom: 4px;"> - <tr><td><?=gettext("Configuration diff from");?> <?php echo date(gettext("n/j/y H:i:s"), $oldtime); ?> <?=gettext("to");?> <?php echo date(gettext("n/j/y H:i:s"), $newtime); ?></td></tr> + <tr><td>Configuration diff from <?php echo date("n/j/y H:i:s", $oldtime); ?> to <?php echo date("n/j/y H:i:s", $newtime); ?></td></tr> <?php foreach ($diff as $line) { switch (substr($line, 0, 1)) { case "+": @@ -136,10 +135,10 @@ include("head.inc"); <td> <?php $tab_array = array(); - $tab_array[0] = array(gettext("Config History"), true, "diag_confbak.php"); - $tab_array[1] = array(gettext("Backup/Restore"), false, "diag_backup.php"); + $tab_array[0] = array("Config History", true, "diag_confbak.php"); + $tab_array[1] = array("Backup/Restore", false, "diag_backup.php"); display_top_tabs($tab_array); - ?> + ?> </td> </tr> <tr> @@ -150,25 +149,25 @@ include("head.inc"); <?php if (is_array($confvers)): ?> <tr> <td colspan="2" valign="middle" align="center" class="list" nowrap><input type="submit" name="diff" value="Diff"></td> - <td width="30%" class="listhdrr"><?=gettext("Date");?></td> - <td width="70%" class="listhdrr"><?=gettext("Configuration Change");?></td> + <td width="30%" class="listhdrr">Date</td> + <td width="70%" class="listhdrr">Configuration Change</td> </tr> <tr valign="top"> <td valign="middle" class="list" nowrap></td> <td class="list"> <input type="radio" name="newtime" value="current"> </td> - <td class="listlr"> <?= date(gettext("n/j/y H:i:s"), $config['revision']['time']) ?></td> + <td class="listlr"> <?= date("n/j/y H:i:s", $config['revision']['time']) ?></td> <td class="listr"> <?= $config['revision']['description'] ?></td> - <td colspan="3" valign="middle" class="list" nowrap><b><?=gettext("Current");?></b></td> + <td colspan="3" valign="middle" class="list" nowrap><b>Current</b></td> </tr> <?php $c = 0; foreach($confvers as $version): if($version['time'] != 0) - $date = date(gettext("n/j/y H:i:s"), $version['time']); + $date = date("n/j/y H:i:s", $version['time']); else - $date = gettext("Unknown"); + $date = "Unknown"; $desc = $version['description']; ?> <tr valign="top"> @@ -180,24 +179,24 @@ include("head.inc"); <input type="radio" name="newtime" value="<?php echo $version['time'];?>"> <? } else { ?> - <? } + <? } $c++; ?> </td> <td class="listlr"> <?= $date ?></td> <td class="listr"> <?= $desc ?></td> <td valign="middle" class="list" nowrap> - <a href="diag_confbak.php?newver=<?=$version['time'];?>" onclick="return confirm('<?=gettext("Revert to this configuration?");?>'")> - <img src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0" alt="<?=gettext("Revert to this configuration");?>" title="<?=gettext("Revert to this configuration");?>"> + <a href="diag_confbak.php?newver=<?=$version['time'];?>" onclick="return confirm('Revert to this configuration?')"> + <img src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0" alt="Revert to this configuration" title="Revert to this configuration"> </a> </td> <td valign="middle" class="list" nowrap> - <a href="diag_confbak.php?rmver=<?=$version['time'];?>" onclick="return confirm('<?=gettext("Delete this configuration backup?");?>')"> - <img src="/themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0" alt="<?=gettext("Remove this backup");?>" title="<?=gettext("Remove this backup");?>"> + <a href="diag_confbak.php?rmver=<?=$version['time'];?>" onclick="return confirm('Delete this configuration backup?')"> + <img src="/themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0" alt="Remove this backup" title="Remove this backup"> </a> </td> <td valign="middle" class="list" nowrap> <a href="diag_confbak.php?getcfg=<?=$version['time'];?>"> - <img src="/themes/<?= $g['theme']; ?>/images/icons/icon_down.gif" width="17" height="17" border="0" alt="<?=gettext("Download this backup");?>" title="<?=gettext("Download this backup");?>"> + <img src="/themes/<?= $g['theme']; ?>/images/icons/icon_down.gif" width="17" height="17" border="0" alt="Download this backup" title="Download this backup"> </a> </td> </tr> @@ -209,7 +208,7 @@ include("head.inc"); <?php else: ?> <tr> <td> - <?php print_info_box(gettext("No backups found.")); ?> + <?php print_info_box("No backups found."); ?> </td> </tr> <?php endif; ?> diff --git a/usr/local/www/diag_defaults.php b/usr/local/www/diag_defaults.php index cde9d54..c462abd 100755 --- a/usr/local/www/diag_defaults.php +++ b/usr/local/www/diag_defaults.php @@ -48,14 +48,14 @@ if ($_POST) { if ($_POST['Submit'] != " No ") { reset_factory_defaults(); system_reboot(); - $rebootmsg = gettext("The system has been reset to factory defaults and is now rebooting. This may take one minute."); + $rebootmsg = "The system has been reset to factory defaults and is now rebooting. This may take one minute."; } else { header("Location: index.php"); exit; } } -$pgtitle = array(gettext("Diagnostics"),gettext("Factory defaults")); +$pgtitle = array("Diagnostics","Factory defaults"); include("head.inc"); ?> @@ -64,22 +64,21 @@ include("head.inc"); <?php include("fbegin.inc"); ?> <?php if ($rebootmsg): echo print_info_box($rebootmsg); else: ?> <form action="diag_defaults.php" method="post"> - <p><strong> <?=gettext("If you click") . " "" . gettext("Yes") . "", " . gettext("the firewall will")?>: - + <p><strong>If you click "Yes", the firewall will: + <ul> - <li><?=gettext("Reset to factory defaults");?></li> - <li><?=gettext("LAN IP address will be reset to 192.168.1.1");?></li> - <li><?=gettext("System will be configured as a DHCP server on the default LAN interface");?></li> - <li><?=gettext("Reboot after changes are installed");?></li> - <li><?=gettext("WAN interface will be set to obtain an address automatically from a DHCP server");?></li> - <li><?=gettext("webConfigurator admin username will be reset to 'admin'");?></li> - <li><?=gettext("webConfigurator admin password will be reset to");?> '<?=$g['product_name']?>'</li> - + <li>Reset to factory defaults</li> + <li>LAN IP address will be reset to 192.168.1.1</li> + <li>System will be configured as a DHCP server on the default LAN interface</li> + <li>Reboot after changes are installed</li> + <li>WAN interface will be set to obtain an address automatically from a DHCP server</li> + <li>webConfigurator admin username will be reset to 'admin'</li> + <li>webConfigurator admin password will be reset to '<?=$g['product_name']?>'</li> </ul> - <?=gettext("Are you sure you want to proceed?");?></strong></p> + Are you sure you want to proceed?</strong></p> <p> - <input name="Submit" type="submit" class="formbtn" value=" <?=gettext("Yes");?> "> - <input name="Submit" type="submit" class="formbtn" value=" <?=gettext("No");?> "> + <input name="Submit" type="submit" class="formbtn" value=" Yes "> + <input name="Submit" type="submit" class="formbtn" value=" No "> </p> </form> <?php endif; ?> diff --git a/usr/local/www/diag_dns.php b/usr/local/www/diag_dns.php index 9d5f51d..abdeea3 100644 --- a/usr/local/www/diag_dns.php +++ b/usr/local/www/diag_dns.php @@ -49,7 +49,7 @@ if ($_POST) { $host_esc = escapeshellarg(trim($_POST['host'])); if (!is_hostname($host) && !is_ipaddr($host)) - $input_errors[] = gettext("Host must be a valid hostname or IP address."); + $input_errors[] = "Host must be a valid hostname or IP address."; // Test resolution speed of each DNS server. if ((is_hostname($host) || is_ipaddr($host))) { @@ -59,7 +59,7 @@ if ($_POST) { $dns_server = $pconfig['dns' . $dnscounter]; $query_time = `dig {$host_esc} @{$dns_server} | grep Query | cut -d':' -f2`; if($query_time == "") - $query_time = gettext("No response"); + $query_time = "No response"; $new_qt = array(); $new_qt['dns_server'] = $dns_server; $new_qt['query_time'] = $query_time; @@ -68,7 +68,7 @@ if ($_POST) { } } - $type = gettext("unknown"); + $type = "unknown"; $resolved = ""; $ipaddr = ""; $hostname = ""; @@ -88,7 +88,7 @@ if ($_POST) { } if ($host == $resolved) { - $resolved = gettext("No record found"); + $resolved = "No record found"; } } } @@ -103,10 +103,10 @@ include("head.inc"); ?> <form action="diag_dns.php" method="post" name="iform" id="iform"> <table width="100%" border="0" cellpadding="6" cellspacing="0"> <tr> - <td colspan="2" valign="top" class="listtopic"> <?=gettext("Resolve DNS hostname or IP");?></td> + <td colspan="2" valign="top" class="listtopic">Resolve DNS hostname or IP</td> </tr> <tr> - <td width="22%" valign="top" class="vncellreq">gettext("Hostname or IP");?></td> + <td width="22%" valign="top" class="vncellreq">Hostname or IP</td> <td width="78%" class="vtable"> <?=$mandfldhtml;?><input name="host" type="text" class="formfld" id="host" size="20" value="<?=htmlspecialchars($host);?>"> <? if ($resolved && $type) { ?> @@ -116,15 +116,15 @@ include("head.inc"); ?> </tr> <?php if($_POST): ?> <tr> - <td width="22%" valign="top" class="vncell"><?=gettext("Resolution time per server");?></td> + <td width="22%" valign="top" class="vncell">Resolution time per server</td> <td width="78%" class="vtable"> <table width="170" border="1" cellpadding="2" style="border-width: 1px 1px 1px 1px; border-collapse: collapse;"> <tr> <td> - <b><?=gettext("Server");?></b> + <b>Server</b> </td> <td> - <b><?=gettext("Query time);></b> + <b>Query time</b> </td> </tr> <?php @@ -148,14 +148,14 @@ include("head.inc"); ?> <?php endif; ?> <?php if (!$input_errors && $ipaddr) { ?> <tr> - <td width="22%" valign="top" class="vncell"><?=gettext("More Information:");?></td> + <td width="22%" valign="top" class="vncell">More Information:</td> <td width="78%" class="vtable"> - <a target="_new" href ="/diag_ping.php?host=<?=$host?>&interface=wan&count=3"><?=gettext("Ping");?></a> <br/> - <a target="_new" href ="/diag_traceroute.php?host=<?=$host?>&ttl=18"><?=gettext("Traceroute");?></a> + <a target="_new" href ="/diag_ping.php?host=<?=$host?>&interface=wan&count=3">Ping</a> <br/> + <a target="_new" href ="/diag_traceroute.php?host=<?=$host?>&ttl=18">Traceroute</a> <p/> - <?=gettext("NOTE: The following links are to external services, so their reliability cannot be guaranteed.");?><br/><br/> - <a target="_new" href="http://private.dnsstuff.com/tools/whois.ch?ip=<?php echo $ipaddr; ?>"><?=gettext("IP WHOIS @ DNS Stuff");?></a><br /> - <a target="_new" href="http://private.dnsstuff.com/tools/ipall.ch?ip=<?php echo $ipaddr; ?>"><?=gettext("IP Info @ DNS Stuff);?></a> + NOTE: The following links are to external services, so their reliability cannot be guaranteed.<br/><br/> + <a target="_new" href="http://private.dnsstuff.com/tools/whois.ch?ip=<?php echo $ipaddr; ?>">IP WHOIS @ DNS Stuff</a><br /> + <a target="_new" href="http://private.dnsstuff.com/tools/ipall.ch?ip=<?php echo $ipaddr; ?>">IP Info @ DNS Stuff</a> </td> </tr> <?php } ?> @@ -163,7 +163,7 @@ include("head.inc"); ?> <td width="22%" valign="top"> </td> <td width="78%"> <br/> - <input name="Submit" type="submit" class="formbtn" value="<?=gettext("DNS Lookup");?>"> + <input name="Submit" type="submit" class="formbtn" value="DNS Lookup"> </td> </tr> </table> diff --git a/usr/local/www/diag_dump_states.php b/usr/local/www/diag_dump_states.php index 7e223c8..c3818f6 100755 --- a/usr/local/www/diag_dump_states.php +++ b/usr/local/www/diag_dump_states.php @@ -50,7 +50,7 @@ if($_GET['action']) { $retval = mwexec("/sbin/pfctl -k '{$srcip}' -k '{$dstip}'"); echo htmlentities("|{$srcip}|{$dstip}|{$retval}|"); } else { - echo gettext("invalid input"); + echo "invalid input"; } exit; } @@ -132,7 +132,7 @@ include("head.inc"); <form action="<?=$_SERVER['SCRIPT_NAME'];?>" method="get"> <table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> - <td><?=gettext("Current state count");?>: <?=$current_statecount?></td> + <td>Current state count: <?=$current_statecount?></td> <td style="font-weight:bold;" align="right"> <?=gettext("Filter expression:");?> <input type="text" name="filter" class="formfld search" value="<?=$_GET['filter'];?>" size="30" /> diff --git a/usr/local/www/diag_ipsec.php b/usr/local/www/diag_ipsec.php index 99b9864..a77d261 100644 --- a/usr/local/www/diag_ipsec.php +++ b/usr/local/www/diag_ipsec.php @@ -45,7 +45,7 @@ global $g; -$pgtitle = array(gettext("Status"),gettext("IPsec")); +$pgtitle = array("Status","IPsec"); require("guiconfig.inc"); include("head.inc"); @@ -69,10 +69,10 @@ $sad = ipsec_dump_sad(); <td> <?php $tab_array = array(); - $tab_array[0] = array(gettext("Overview"), true, "diag_ipsec.php"); - $tab_array[1] = array(gettext("SAD"), false, "diag_ipsec_sad.php"); - $tab_array[2] = array(gettext("SPD"), false, "diag_ipsec_spd.php"); - $tab_array[3] = array(gettext("Logs"), false, "diag_logs_ipsec.php"); + $tab_array[0] = array("Overview", true, "diag_ipsec.php"); + $tab_array[1] = array("SAD", false, "diag_ipsec_sad.php"); + $tab_array[2] = array("SPD", false, "diag_ipsec_spd.php"); + $tab_array[3] = array("Logs", false, "diag_logs_ipsec.php"); display_top_tabs($tab_array); ?> </td> @@ -82,12 +82,12 @@ $sad = ipsec_dump_sad(); <div id="mainarea"> <table width="100%" border="0" cellpadding="6" cellspacing="0" class="tabcont sortable"> <tr> - <td nowrap class="listhdrr"><?=gettext("Local IP");?></td> - <td nowrap class="listhdrr"><?=gettext("Remote IP");?></a></td> - <td nowrap class="listhdrr"><?=gettext("Local Network");?></td> - <td nowrap class="listhdrr"><?=gettext("Remote Network");?></a></td> - <td nowrap class="listhdrr"><?=gettext("Description");?></a></td> - <td nowrap class="listhdrr"><?=gettext("Status");?></td> + <td nowrap class="listhdrr">Local IP</td> + <td nowrap class="listhdrr">Remote IP</a></td> + <td nowrap class="listhdrr">Local Network</td> + <td nowrap class="listhdrr">Remote Network</a></td> + <td nowrap class="listhdrr">Description</a></td> + <td nowrap class="listhdrr">Status</td> </tr> <?php foreach ($a_phase2 as $ph2ent) { @@ -132,9 +132,9 @@ $sad = ipsec_dump_sad(); <span class="vexpl"> <span class="red"> - <strong><?=gettext("Note");?>:<br /></strong> + <strong>Note:<br /></strong> </span> - <?=gettext("You can configure your IPsec");?> + You can configure your IPsec <a href="vpn_ipsec.php">here</a>. </span> diff --git a/usr/local/www/diag_ipsec_sad.php b/usr/local/www/diag_ipsec_sad.php index 3af1e69..75ec782 100755 --- a/usr/local/www/diag_ipsec_sad.php +++ b/usr/local/www/diag_ipsec_sad.php @@ -46,7 +46,7 @@ require("guiconfig.inc"); require("ipsec.inc"); -$pgtitle = array(gettext("Status"),gettext("IPsec"),gettext("SAD")); +$pgtitle = array("Status","IPsec","SAD"); include("head.inc"); $sad = ipsec_dump_sad(); @@ -70,10 +70,10 @@ if ($_GET['act'] == "del") { <td> <?php $tab_array = array(); - $tab_array[0] = array(gettext("Overview"), false, "diag_ipsec.php"); - $tab_array[1] = array(gettext("SAD"), true, "diag_ipsec_sad.php"); - $tab_array[2] = array(gettext("SPD"), false, "diag_ipsec_spd.php"); - $tab_array[3] = array(gettext("Logs"), false, "diag_logs_ipsec.php"); + $tab_array[0] = array("Overview", false, "diag_ipsec.php"); + $tab_array[1] = array("SAD", true, "diag_ipsec_sad.php"); + $tab_array[2] = array("SPD", false, "diag_ipsec_spd.php"); + $tab_array[3] = array("Logs", false, "diag_logs_ipsec.php"); display_top_tabs($tab_array); ?> </td> @@ -84,12 +84,12 @@ if ($_GET['act'] == "del") { <table class="tabcont sortable" width="100%" border="0" cellpadding="6" cellspacing="0"> <?php if (count($sad)): ?> <tr> - <td nowrap class="listhdrr"><?=gettext("Source");?></td> - <td nowrap class="listhdrr"><?=gettext("Destination");?></a></td> - <td nowrap class="listhdrr"><?=gettext("Protocol");?></td> - <td nowrap class="listhdrr"><?=gettext("SPI");?></td> - <td nowrap class="listhdrr"><?=gettext("Enc. alg.");?></td> - <td nowrap class="listhdr"><?=gettext("Auth. alg.");?></td> + <td nowrap class="listhdrr">Source</td> + <td nowrap class="listhdrr">Destination</a></td> + <td nowrap class="listhdrr">Protocol</td> + <td nowrap class="listhdrr">SPI</td> + <td nowrap class="listhdrr">Enc. alg.</td> + <td nowrap class="listhdr">Auth. alg.</td> <td nowrap class="list"></td> </tr> <?php foreach ($sad as $sa): ?> @@ -116,7 +116,7 @@ if ($_GET['act'] == "del") { <?php else: ?> <tr> <td> - <p><strong><?=gettext("No IPsec security associations.");?></strong></p> + <p><strong>No IPsec security associations.</strong></p> </td> </tr> <?php endif; ?> @@ -129,8 +129,8 @@ if ($_GET['act'] == "del") { <p/> <span class="vexpl"> -<span class="red"><strong><?=gettext("Note");?>:<br></strong></span> -<?=gettext("You can configure your IPsec");?> <a href="vpn_ipsec.php">here</a>. +<span class="red"><strong>Note:<br></strong></span> +You can configure your IPsec <a href="vpn_ipsec.php">here</a>. </span> <?php include("fend.inc"); ?> diff --git a/usr/local/www/diag_ipsec_spd.php b/usr/local/www/diag_ipsec_spd.php index 8621e59..3d44b62 100755 --- a/usr/local/www/diag_ipsec_spd.php +++ b/usr/local/www/diag_ipsec_spd.php @@ -46,7 +46,7 @@ require("guiconfig.inc"); require("ipsec.inc"); -$pgtitle = array(gettext("Status"),gettext("IPsec"),gettext("SPD")); +$pgtitle = array("Status","IPsec","SPD"); include("head.inc"); /* delete any SP? */ @@ -69,10 +69,10 @@ $spd = ipsec_dump_spd(); <td> <?php $tab_array = array(); - $tab_array[0] = array(gettext("Overview"), false, "diag_ipsec.php"); - $tab_array[1] = array(gettext("SAD"), false, "diag_ipsec_sad.php"); - $tab_array[2] = array(gettext("SPD"), true, "diag_ipsec_spd.php"); - $tab_array[3] = array(gettext("Logs"), false, "diag_logs_ipsec.php"); + $tab_array[0] = array("Overview", false, "diag_ipsec.php"); + $tab_array[1] = array("SAD", false, "diag_ipsec_sad.php"); + $tab_array[2] = array("SPD", true, "diag_ipsec_spd.php"); + $tab_array[3] = array("Logs", false, "diag_logs_ipsec.php"); display_top_tabs($tab_array); ?> </td> @@ -83,11 +83,11 @@ $spd = ipsec_dump_spd(); <table class="tabcont sortable" width="100%" border="0" cellpadding="6" cellspacing="0"> <?php if (count($spd)): ?> <tr> - <td nowrap class="listhdrr"><?= gettext("Source"); ?></td> - <td nowrap class="listhdrr"><?= gettext("Destination"); ?></td> - <td nowrap class="listhdrr"><?= gettext("Direction"); ?></td> - <td nowrap class="listhdrr"><?= gettext("Protocol"); ?></td> - <td nowrap class="listhdrr"><?= gettext("Tunnel endpoints"); ?></td> + <td nowrap class="listhdrr">Source</td> + <td nowrap class="listhdrr">Destination</td> + <td nowrap class="listhdrr">Direction</td> + <td nowrap class="listhdrr">Protocol</td> + <td nowrap class="listhdrr">Tunnel endpoints</td> <td nowrap class="list"></td> </tr> <?php foreach ($spd as $sp): ?> @@ -105,7 +105,7 @@ $spd = ipsec_dump_spd(); $args .= "&dstid=".rawurlencode($sp['dstid']); $args .= "&dir=".rawurlencode($sp['dir']); ?> - <a href="diag_ipsec_spd.php?act=del&<?=$args;?>" onclick="return confirm('<?= gettext("Do you really want to delete this security policy?"); ?>')"> + <a href="diag_ipsec_spd.php?act=del&<?=$args;?>" onclick="return confirm('Do you really want to delete this security policy?')"> <img src="/themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"> </a> </td> @@ -116,19 +116,19 @@ $spd = ipsec_dump_spd(); <table class="tabcont" border="0" cellspacing="0" cellpadding="6"> <tr> <td width="16"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_in.gif" width="11" height="11"></td> - <td><?= gettext("incoming (as seen by firewall)"); ?></td> + <td>incoming (as seen by firewall)</td> </tr> <tr> <td colspan="5" height="4"></td> </tr> <tr> <td><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_out.gif" width="11" height="11"></td> - <td><?= gettext("outgoing (as seen by firewall)"); ?></td> + <td>outgoing (as seen by firewall)</td> </tr> <?php else: ?> <tr> <td> - <p><strong><?= gettext("No IPsec security policies."); ?></strong></p> + <p><strong>No IPsec security policies.</strong></p> </td> </tr> <?php endif; ?> @@ -140,8 +140,8 @@ $spd = ipsec_dump_spd(); <p> <span class="vexpl"> -<span class="red"><strong><?= gettext("Note"); ?>:<br></strong></span> -<?= gettext("You can configure your IPsec"); ?> <a href="vpn_ipsec.php"><?= gettext("here"); ?></a>. +<span class="red"><strong>Note:<br></strong></span> +You can configure your IPsec <a href="vpn_ipsec.php">here</a>. </span> <?php include("fend.inc"); ?> diff --git a/usr/local/www/diag_logs.php b/usr/local/www/diag_logs.php index 145d480..85b61df 100755 --- a/usr/local/www/diag_logs.php +++ b/usr/local/www/diag_logs.php @@ -62,7 +62,7 @@ if ($_POST['filtertext']) if ($filtertext) $filtertextmeta="?filtertext=$filtertext"; -$pgtitle = array(gettext("Status"),gettext("System logs"),gettext("System")); +$pgtitle = array("Status","System logs","System"); include("head.inc"); ?> @@ -74,17 +74,17 @@ include("head.inc"); <td> <?php $tab_array = array(); - $tab_array[] = array(gettext("System"), true, "diag_logs.php"); - $tab_array[] = array(gettext("Firewall"), false, "diag_logs_filter.php"); - $tab_array[] = array(gettext("DHCP"), false, "diag_logs_dhcp.php"); - $tab_array[] = array(gettext("Portal Auth"), false, "diag_logs_auth.php"); - $tab_array[] = array(gettext("IPsec"), false, "diag_logs_ipsec.php"); - $tab_array[] = array(gettext("PPP"), false, "diag_logs_ppp.php"); - $tab_array[] = array(gettext("VPN"), false, "diag_logs_vpn.php"); - $tab_array[] = array(gettext("Load Balancer"), false, "diag_logs_relayd.php"); - $tab_array[] = array(gettext("OpenVPN"), false, "diag_logs_openvpn.php"); - $tab_array[] = array(gettext("OpenNTPD"), false, "diag_logs_ntpd.php"); - $tab_array[] = array(gettext("Settings"), false, "diag_logs_settings.php"); + $tab_array[] = array("System", true, "diag_logs.php"); + $tab_array[] = array("Firewall", false, "diag_logs_filter.php"); + $tab_array[] = array("DHCP", false, "diag_logs_dhcp.php"); + $tab_array[] = array("Portal Auth", false, "diag_logs_auth.php"); + $tab_array[] = array("IPsec", false, "diag_logs_ipsec.php"); + $tab_array[] = array("PPP", false, "diag_logs_ppp.php"); + $tab_array[] = array("VPN", false, "diag_logs_vpn.php"); + $tab_array[] = array("Load Balancer", false, "diag_logs_relayd.php"); + $tab_array[] = array("OpenVPN", false, "diag_logs_openvpn.php"); + $tab_array[] = array("OpenNTPD", false, "diag_logs_ntpd.php"); + $tab_array[] = array("Settings", false, "diag_logs_settings.php"); display_top_tabs($tab_array); ?> </td> @@ -94,7 +94,7 @@ include("head.inc"); <div id="mainarea"> <table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> - <td colspan="2" class="listtopic"><?php printf(gettext("Last %s system log entries"),$nentries); ?></td> + <td colspan="2" class="listtopic">Last <?=$nentries;?> system log entries</td> </tr> <?php if($filtertext) @@ -110,7 +110,7 @@ include("head.inc"); </td> <td align="right" valign="top" > <form id="clearform" name="clearform" action="diag_logs.php" method="post" style="margin-top: 14px;"> - <input id="filtertext" name="filtertext" value="<?=$filtertext;?>" /> + <input id="filtertext" name="filtertext" value="<?=gettext($filtertext);?>" /> <input id="filtersubmit" name="filtersubmit" type="submit" class="formbtn" value="<?=gettext("Filter");?>" /> </form> </td> diff --git a/usr/local/www/diag_logs_auth.php b/usr/local/www/diag_logs_auth.php index a6e9730..700b6dc 100755 --- a/usr/local/www/diag_logs_auth.php +++ b/usr/local/www/diag_logs_auth.php @@ -51,7 +51,7 @@ if (!$nentries) if ($_POST['clear']) clear_log_file($portal_logfile); -$pgtitle = array(gettext("Status"),gettext("System logs"),gettext("Portal Auth")); +$pgtitle = array("Status","System logs","Portal Auth"); include("head.inc"); ?> @@ -62,17 +62,17 @@ include("head.inc"); <tr><td> <?php $tab_array = array(); - $tab_array[] = array(gettext("System"), false, "diag_logs.php"); - $tab_array[] = array(gettext("Firewall"), false, "diag_logs_filter.php"); - $tab_array[] = array(gettext("DHCP"), false, "diag_logs_dhcp.php"); - $tab_array[] = array(gettext("Portal Auth"), true, "diag_logs_auth.php"); - $tab_array[] = array(gettext("IPsec"), false, "diag_logs_ipsec.php"); - $tab_array[] = array(gettext("PPP"), false, "diag_logs_ppp.php"); - $tab_array[] = array(gettext("VPN"), false, "diag_logs_vpn.php"); - $tab_array[] = array(gettext("Load Balancer"), false, "diag_logs_relayd.php"); - $tab_array[] = array(gettext("OpenVPN"), false, "diag_logs_openvpn.php"); - $tab_array[] = array(gettext("OpenNTPD"), false, "diag_logs_ntpd.php"); - $tab_array[] = array(gettext("Settings"), false, "diag_logs_settings.php"); + $tab_array[] = array("System", false, "diag_logs.php"); + $tab_array[] = array("Firewall", false, "diag_logs_filter.php"); + $tab_array[] = array("DHCP", false, "diag_logs_dhcp.php"); + $tab_array[] = array("Portal Auth", true, "diag_logs_auth.php"); + $tab_array[] = array("IPsec", false, "diag_logs_ipsec.php"); + $tab_array[] = array("PPP", false, "diag_logs_ppp.php"); + $tab_array[] = array("VPN", false, "diag_logs_vpn.php"); + $tab_array[] = array("Load Balancer", false, "diag_logs_relayd.php"); + $tab_array[] = array("OpenVPN", false, "diag_logs_openvpn.php"); + $tab_array[] = array("OpenNTPD", false, "diag_logs_ntpd.php"); + $tab_array[] = array("Settings", false, "diag_logs_settings.php"); display_top_tabs($tab_array); ?> </td></tr> @@ -82,11 +82,11 @@ include("head.inc"); <table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td colspan="2" class="listtopic"> - <?php printf(gettext("Last %s Portal Auth log entries"),$nentries);?></td> + Last <?=$nentries;?> Portal Auth log entries</td> </tr> <?php dump_clog($portal_logfile, $nentries, true); ?> <tr><td><br><form action="diag_logs_auth.php" method="post"> - <input name="clear" type="submit" class="formbtn" value="<?= gettext("Clear log"); ?>"></td></tr> + <input name="clear" type="submit" class="formbtn" value="Clear log"></td></tr> </table> </div> </form> diff --git a/usr/local/www/diag_logs_dhcp.php b/usr/local/www/diag_logs_dhcp.php index ffc51c4..b95b969 100755 --- a/usr/local/www/diag_logs_dhcp.php +++ b/usr/local/www/diag_logs_dhcp.php @@ -53,7 +53,7 @@ if (!$nentries) if ($_POST['clear']) clear_log_file($dhcpd_logfile); -$pgtitle = array(gettext("Status"),gettext("System logs"),gettext("DHCP")); +$pgtitle = array("Status","System logs","DHCP"); include("head.inc"); ?> @@ -64,17 +64,17 @@ include("head.inc"); <tr><td> <?php $tab_array = array(); - $tab_array[] = array(gettext("System"), false, "diag_logs.php"); - $tab_array[] = array(gettext("Firewall"), false, "diag_logs_filter.php"); - $tab_array[] = array(gettext("DHCP"), true, "diag_logs_dhcp.php"); - $tab_array[] = array(gettext("Portal Auth"), false, "diag_logs_auth.php"); - $tab_array[] = array(gettext("IPsec"), false, "diag_logs_ipsec.php"); - $tab_array[] = array(gettext("PPP"), false, "diag_logs_ppp.php"); - $tab_array[] = array(gettext("VPN"), false, "diag_logs_vpn.php"); - $tab_array[] = array(gettext("Load Balancer"), false, "diag_logs_relayd.php"); - $tab_array[] = array(gettext("OpenVPN"), false, "diag_logs_openvpn.php"); - $tab_array[] = array(gettext("OpenNTPD"), false, "diag_logs_ntpd.php"); - $tab_array[] = array(gettext("Settings"), false, "diag_logs_settings.php"); + $tab_array[] = array("System", false, "diag_logs.php"); + $tab_array[] = array("Firewall", false, "diag_logs_filter.php"); + $tab_array[] = array("DHCP", true, "diag_logs_dhcp.php"); + $tab_array[] = array("Portal Auth", false, "diag_logs_auth.php"); + $tab_array[] = array("IPsec", false, "diag_logs_ipsec.php"); + $tab_array[] = array("PPP", false, "diag_logs_ppp.php"); + $tab_array[] = array("VPN", false, "diag_logs_vpn.php"); + $tab_array[] = array("Load Balancer", false, "diag_logs_relayd.php"); + $tab_array[] = array("OpenVPN", false, "diag_logs_openvpn.php"); + $tab_array[] = array("OpenNTPD", false, "diag_logs_ntpd.php"); + $tab_array[] = array("Settings", false, "diag_logs_settings.php"); display_top_tabs($tab_array); ?> </td></tr> @@ -84,11 +84,11 @@ include("head.inc"); <table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td colspan="2" class="listtopic"> - <?php printf(gettext("Last %s DHCP service log entries"), $nentries);?></td> + Last <?=$nentries;?> DHCP service log entries</td> </tr> <?php dump_clog($dhcpd_logfile, $nentries); ?> <tr><td><br><form action="diag_logs_dhcp.php" method="post"> - <input name="clear" type="submit" class="formbtn" value="<?= gettext("Clear log");?>"></td></tr> + <input name="clear" type="submit" class="formbtn" value="Clear log"></td></tr> </table> </div> </form> diff --git a/usr/local/www/diag_logs_filter.php b/usr/local/www/diag_logs_filter.php index 02b2591..9d8d9cd 100755 --- a/usr/local/www/diag_logs_filter.php +++ b/usr/local/www/diag_logs_filter.php @@ -53,7 +53,7 @@ if($_GET['getrulenum'] or $_POST['getrulenum']) { $rulenum = $_POST['getrulenum']; list($rulenum, $type) = explode(',', $rulenum); $rule = find_rule_by_number($rulenum, $type); - echo gettext("The rule that triggered this action is") . ":\n\n{$rule}"; + echo "The rule that triggered this action is:\n\n{$rule}"; exit; } @@ -87,7 +87,7 @@ if (!$nentries) if ($_POST['clear']) clear_log_file($filter_logfile); -$pgtitle = array(gettext("Status"),gettext("System logs"),gettext("Firewall")); +$pgtitle = array("Status","System logs","Firewall"); include("head.inc"); ?> @@ -98,17 +98,17 @@ include("head.inc"); <tr><td> <?php $tab_array = array(); - $tab_array[] = array(gettext("System"), false, "diag_logs.php"); - $tab_array[] = array(gettext("Firewall"), true, "diag_logs_filter.php"); - $tab_array[] = array(gettext("DHCP"), false, "diag_logs_dhcp.php"); - $tab_array[] = array(gettext("Portal Auth"), false, "diag_logs_auth.php"); - $tab_array[] = array(gettext("IPsec"), false, "diag_logs_ipsec.php"); - $tab_array[] = array(gettext("PPP"), false, "diag_logs_ppp.php"); - $tab_array[] = array(gettext("VPN"), false, "diag_logs_vpn.php"); - $tab_array[] = array(gettext("Load Balancer"), false, "diag_logs_relayd.php"); - $tab_array[] = array(gettext("OpenVPN"), false, "diag_logs_openvpn.php"); - $tab_array[] = array(gettext("OpenNTPD"), false, "diag_logs_ntpd.php"); - $tab_array[] = array(gettext("Settings"), false, "diag_logs_settings.php"); + $tab_array[] = array("System", false, "diag_logs.php"); + $tab_array[] = array("Firewall", true, "diag_logs_filter.php"); + $tab_array[] = array("DHCP", false, "diag_logs_dhcp.php"); + $tab_array[] = array("Portal Auth", false, "diag_logs_auth.php"); + $tab_array[] = array("IPsec", false, "diag_logs_ipsec.php"); + $tab_array[] = array("PPP", false, "diag_logs_ppp.php"); + $tab_array[] = array("VPN", false, "diag_logs_vpn.php"); + $tab_array[] = array("Load Balancer", false, "diag_logs_relayd.php"); + $tab_array[] = array("OpenVPN", false, "diag_logs_openvpn.php"); + $tab_array[] = array("OpenNTPD", false, "diag_logs_ntpd.php"); + $tab_array[] = array("Settings", false, "diag_logs_settings.php"); display_top_tabs($tab_array); ?> </td></tr> @@ -117,7 +117,7 @@ include("head.inc"); <div id="mainarea"> <table class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0"> <tr><td colspan="6" align="left"> - <?=gettext("Normal View");?> | <a href="diag_logs_filter_dynamic.php"><?=gettext("Dynamic View");?></a> | <a href="diag_logs_filter_summary.php"><?=gettext("Summary View");?></a><br/><br/> + Normal View | <a href="diag_logs_filter_dynamic.php">Dynamic View</a> | <a href="diag_logs_filter_summary.php">Summary View</a><br/><br/> </td></tr> <?php if (!isset($config['syslog']['rawfilter'])): $filterlog = conv_log_filter($filter_logfile, $nentries, $nentries + 100, $filtertext); @@ -125,19 +125,19 @@ include("head.inc"); <tr> <td colspan="6" class="listtopic"> <?php if (!$filtertext) { ?> - <?php printf(gettext("Last %s firewall log entries."),count($filterlog));?> + Last <?php echo count($filterlog);?> firewall log entries. <?php } else { ?> - <?php echo count($filterlog). ' ' . gettext("matched log entries."); ?> + <?php echo count($filterlog);?> matched log entries. <?php } ?> - <?php printf(gettext("Max(%s)"),$nentries);?> + (Max <?php echo $nentries;?>) </tr> <tr> - <td width="10%" class="listhdrr"><?=gettext("Act");?></td> - <td width="10%" class="listhdrr"><?=gettext("Time");?></td> - <td width="15%" class="listhdrr"><?=gettext("If");?></td> - <td width="25%" class="listhdrr"><?=gettext("Source");?></td> - <td width="25%" class="listhdrr"><?=gettext("Destination");?></td> - <td width="15%" class="listhdrr"><?=gettext("Proto");?></td> + <td width="10%" class="listhdrr">Act</td> + <td width="10%" class="listhdrr">Time</td> + <td width="15%" class="listhdrr">If</td> + <td width="25%" class="listhdrr">Source</td> + <td width="25%" class="listhdrr">Destination</td> + <td width="15%" class="listhdrr">Proto</td> </tr><?php foreach ($filterlog as $filterent): ?> <tr> <td class="listlr" nowrap align="middle"> @@ -155,13 +155,13 @@ include("head.inc"); $dststr = $filterent['dstip'] . get_port_with_service($filterent['dstport'], $proto); ?> <td class="listr" nowrap> - <a href="diag_dns.php?host=<?php echo $filterent['srcip']; ?>" title="<?=gettext("Reverse Resolve with DNS");?>"><img border="0" src="/themes/nervecenter/images/icons/icon_log.gif"></a> - <a href="easyrule.php?<?php echo "action=block&int={$int}&src={$filterent['srcip']}"; ?>" title="<?=gettext("Easy Rule: Add to Block List");?>" onclick="return confirm('<?=gettext("Do you really want to add this BLOCK rule?")."\n\n".gettext("Easy Rule is still experimental.")."\n".gettext("Continue at risk of your own peril.")."\n".gettext("Backups are also nice.")?>')"><img border="0" src="/themes/nervecenter/images/icons/icon_block_add.gif"></a> + <a href="diag_dns.php?host=<?php echo $filterent['srcip']; ?>" title="Reverse Resolve with DNS"><img border="0" src="/themes/nervecenter/images/icons/icon_log.gif"></a> + <a href="easyrule.php?<?php echo "action=block&int={$int}&src={$filterent['srcip']}"; ?>" title="Easy Rule: Add to Block List" onclick="return confirm('Do you really want to add this BLOCK rule?\n\nEasy Rule is still experimental.\nContinue at risk of your own peril.\nBackups are also nice.')"><img border="0" src="/themes/nervecenter/images/icons/icon_block_add.gif"></a> <?php echo $srcstr;?> </td> <td class="listr" nowrap> - <a href="diag_dns.php?host=<?php echo $filterent['dstip']; ?>" title="<?=gettext("Reverse Resolve with DNS");?>"><img border="0" src="/themes/nervecenter/images/icons/icon_log.gif"></a> - <a href="easyrule.php?<?php echo "action=pass&int={$int}&proto={$proto}&src={$filterent['srcip']}&dst={$filterent['dstip']}&dstport={$filterent['dstport']}"; ?>" title="<?=gettext("Easy Rule: Pass this traffic");?>" onclick="return confirm('<?=gettext("Do you really want to add this PASS rule?")."\n\n".gettext("Easy Rule is still experimental.")."\n".gettext("Continue at risk of your own peril.")."\n".gettext("Backups are also nice.");?>')"><img border="0" src="/themes/nervecenter/images/icons/icon_pass_add.gif"></a> + <a href="diag_dns.php?host=<?php echo $filterent['dstip']; ?>" title="Reverse Resolve with DNS"><img border="0" src="/themes/nervecenter/images/icons/icon_log.gif"></a> + <a href="easyrule.php?<?php echo "action=pass&int={$int}&proto={$proto}&src={$filterent['srcip']}&dst={$filterent['dstip']}&dstport={$filterent['dstport']}"; ?>" title="Easy Rule: Pass this traffic" onclick="return confirm('Do you really want to add this PASS rule?\n\nEasy Rule is still experimental.\nContinue at risk of your own peril.\nBackups are also nice.')"><img border="0" src="/themes/nervecenter/images/icons/icon_pass_add.gif"></a> <?php echo $dststr;?> </td> <?php @@ -173,7 +173,7 @@ include("head.inc"); <?php else: ?> <tr> <td colspan="2" class="listtopic"> - <?php printf(gettext("Last %s firewall log entries"),$nentries);?></td> + Last <?php echo $nentries;?> firewall log entries</td> </tr> <?php if($filtertext) diff --git a/usr/local/www/diag_logs_filter_dynamic.php b/usr/local/www/diag_logs_filter_dynamic.php index 52a2076..a07b52b 100755 --- a/usr/local/www/diag_logs_filter_dynamic.php +++ b/usr/local/www/diag_logs_filter_dynamic.php @@ -58,7 +58,7 @@ if ($_POST['clear']) $filterlog = conv_log_filter($filter_logfile, $nentries, $nentries + 100); -$pgtitle = array(gettext("Diagnostics"),gettext("System logs"),gettext("Firewall")); +$pgtitle = array("Diagnostics","System logs","Firewall"); include("head.inc"); ?> @@ -97,17 +97,17 @@ include("head.inc"); <tr><td> <?php $tab_array = array(); - $tab_array[] = array(gettext("System"), false, "diag_logs.php"); - $tab_array[] = array(gettext("Firewall"), true, "diag_logs_filter.php"); - $tab_array[] = array(gettext("DHCP"), false, "diag_logs_dhcp.php"); - $tab_array[] = array(gettext("Portal Auth"), false, "diag_logs_auth.php"); - $tab_array[] = array(gettext("IPsec"), false, "diag_logs_ipsec.php"); - $tab_array[] = array(gettext("PPP"), false, "diag_logs_ppp.php"); - $tab_array[] = array(gettext("VPN"), false, "diag_logs_vpn.php"); - $tab_array[] = array(gettext("Load Balancer"), false, "diag_logs_relayd.php"); - $tab_array[] = array(gettext("OpenVPN"), false, "diag_logs_openvpn.php"); - $tab_array[] = array(gettext("OpenNTPD"), false, "diag_logs_ntpd.php"); - $tab_array[] = array(gettext("Settings"), false, "diag_logs_settings.php"); + $tab_array[] = array("System", false, "diag_logs.php"); + $tab_array[] = array("Firewall", true, "diag_logs_filter.php"); + $tab_array[] = array("DHCP", false, "diag_logs_dhcp.php"); + $tab_array[] = array("Portal Auth", false, "diag_logs_auth.php"); + $tab_array[] = array("IPsec", false, "diag_logs_ipsec.php"); + $tab_array[] = array("PPP", false, "diag_logs_ppp.php"); + $tab_array[] = array("VPN", false, "diag_logs_vpn.php"); + $tab_array[] = array("Load Balancer", false, "diag_logs_relayd.php"); + $tab_array[] = array("OpenVPN", false, "diag_logs_openvpn.php"); + $tab_array[] = array("OpenNTPD", false, "diag_logs_ntpd.php"); + $tab_array[] = array("Settings", false, "diag_logs_settings.php"); display_top_tabs($tab_array); ?> </td></tr> @@ -115,19 +115,19 @@ include("head.inc"); <td> <div id="mainarea"> <div class="tabcont"> - <a href="diag_logs_filter.php"><?=gettext("Normal View");?></a> | <?=gettext("Dynamic View");?> | <a href="diag_logs_filter_summary.php"><?=gettext("Summary View");?></a> + <a href="diag_logs_filter.php">Normal View</a> | Dynamic View | <a href="diag_logs_filter_summary.php">Summary View</a> </div> <div class="listtopic"> - <?php printf(gettext("Last %s records"),$nentries);?>; <?=gettext("Pause");?>:<input valign="middle" type="checkbox" onClick="javascript:toggle_pause();"> + Last <?php echo $nentries; ?> records; Pause:<input valign="middle" type="checkbox" onClick="javascript:toggle_pause();"> </div> <div id="log"> <div class="log-header"> - <span class="log-action"><?=gettext("Act");?></span> - <span class="log-time"><?=gettext("Time");?></span> - <span class="log-interface"><?=gettext("If");?></span> - <span class="log-source"><?=gettext("Source");?></span> - <span class="log-destination"><?=gettext("Destination");?></span> - <span class="log-protocol"><?=gettext("Proto");?></span> + <span class="log-action">Act</span> + <span class="log-time">Time</span> + <span class="log-interface">If</span> + <span class="log-source">Source</span> + <span class="log-destination">Destination</span> + <span class="log-protocol">Proto</span> </div> <?php $counter=0; foreach ($filterlog as $filterent): ?> <div class="log-entry"<?php echo is_first_row($counter, count($filterlog)); ?>> diff --git a/usr/local/www/diag_logs_filter_summary.php b/usr/local/www/diag_logs_filter_summary.php index 1171b89..4904127 100644 --- a/usr/local/www/diag_logs_filter_summary.php +++ b/usr/local/www/diag_logs_filter_summary.php @@ -31,7 +31,7 @@ pfSense_MODULE: filter */ -$pgtitle = gettext("Diagnostics").": ".gettext("System logs").": ".gettext("Firewall Log Summary"); +$pgtitle = "Diagnostics: System logs: Firewall Log Summary"; require_once("guiconfig.inc"); include_once("filter_log.inc"); @@ -42,13 +42,13 @@ $entriesperblock = 5; $filterlog = conv_log_filter($filter_logfile, $lines, $lines); $gotlines = count($filterlog); $fields = array( - 'act' => gettext("Actions"), - 'interface' => gettext("Interfaces"), - 'proto' => gettext("Protocols"), - 'srcip' => gettext("Source IPs"), - 'dstip' => gettext("Destination IPs"), - 'srcport' => gettext("Source Ports"), - 'dstport' => gettext("Destination Ports")); + 'act' => "Actions", + 'interface' => "Interfaces", + 'proto' => "Protocols", + 'srcip' => "Source IPs", + 'dstip' => "Destination IPs", + 'srcport' => "Source Ports", + 'dstport' => "Destination Ports"); $summary = array(); foreach (array_keys($fields) as $f) { @@ -68,7 +68,7 @@ function stat_block($summary, $stat, $num) { global $gotlines, $fields; uasort($summary[$stat] , 'cmp'); print '<table width="200px" cellpadding="3" cellspacing="0" border="1">'; - print "<tr><th colspan='2'>{$fields[$stat]} ".gettext("data")."</th></tr>"; + print "<tr><th colspan='2'>{$fields[$stat]} data</th></tr>"; $k = array_keys($summary[$stat]); $total = 0; $numentries = 0; @@ -78,7 +78,7 @@ function stat_block($summary, $stat, $num) { $numentries++; $outstr = $k[$i]; if (is_ipaddr($outstr)) { - $outstr = "<a href=\"diag_dns.php?host={$outstr}\" title=\"".gettext("Reverse Resolve with DNS")."\"><img border=\"0\" src=\"/themes/nervecenter/images/icons/icon_log.gif\"></a> {$outstr}"; + $outstr = "<a href=\"diag_dns.php?host={$outstr}\" title=\"Reverse Resolve with DNS\"><img border=\"0\" src=\"/themes/nervecenter/images/icons/icon_log.gif\"></a> {$outstr}"; } elseif (substr_count($outstr, '/') == 1) { list($proto, $port) = explode('/', $outstr); $service = getservbyport($port, strtolower($proto)); @@ -181,17 +181,17 @@ include("head.inc"); ?> <tr><td> <?php $tab_array = array(); - $tab_array[] = array(gettext("System"), false, "diag_logs.php"); - $tab_array[] = array(gettext("Firewall"), true, "diag_logs_filter.php"); - $tab_array[] = array(gettext("DHCP"), false, "diag_logs_dhcp.php"); - $tab_array[] = array(gettext("Portal Auth"), false, "diag_logs_auth.php"); - $tab_array[] = array(gettext("IPsec"), false, "diag_logs_ipsec.php"); - $tab_array[] = array(gettext("PPP"), false, "diag_logs_ppp.php"); - $tab_array[] = array(gettext("VPN"), false, "diag_logs_vpn.php"); - $tab_array[] = array(gettext("Load Balancer"), false, "diag_logs_relayd.php"); - $tab_array[] = array(gettext("OpenVPN"), false, "diag_logs_openvpn.php"); - $tab_array[] = array(gettext("OpenNTPD"), false, "diag_logs_ntpd.php"); - $tab_array[] = array(gettext("Settings"), false, "diag_logs_settings.php"); + $tab_array[] = array("System", false, "diag_logs.php"); + $tab_array[] = array("Firewall", true, "diag_logs_filter.php"); + $tab_array[] = array("DHCP", false, "diag_logs_dhcp.php"); + $tab_array[] = array("Portal Auth", false, "diag_logs_auth.php"); + $tab_array[] = array("IPsec", false, "diag_logs_ipsec.php"); + $tab_array[] = array("PPP", false, "diag_logs_ppp.php"); + $tab_array[] = array("VPN", false, "diag_logs_vpn.php"); + $tab_array[] = array("Load Balancer", false, "diag_logs_relayd.php"); + $tab_array[] = array("OpenVPN", false, "diag_logs_openvpn.php"); + $tab_array[] = array("OpenNTPD", false, "diag_logs_ntpd.php"); + $tab_array[] = array("Settings", false, "diag_logs_settings.php"); display_top_tabs($tab_array); ?> </td></tr> @@ -200,12 +200,12 @@ include("head.inc"); ?> <div id="mainarea"> <table class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0" align="center"> <tr><td colspan="6" align="left"> - <a href="diag_logs_filter.php"><?=gettext("Normal View");?></a> | <a href="diag_logs_filter_dynamic.php"><?=gettext("Dynamic View");?></a> | <?=gettext("Summary View");?><br/><br/> + <a href="diag_logs_filter.php">Normal View</a> | <a href="diag_logs_filter_dynamic.php">Dynamic View</a> | Summary View<br/><br/> </td></tr> <tr><td align="center"> -<?php printf (gettext("This is a firewall log summary, of the last %s lines of the firewall log (Max %s)."), $gotlines, $lines)?><br /> -<?=gettext("NOTE: IE8 users must enable compatibility view.")?> +This is a firewall log summary, of the last <?php echo $gotlines; ?> lines of the firewall log (Max <?php echo $lines; ?>).<br /> +NOTE: IE8 users must enable compatibility view. <?php foreach(array_keys($fields) as $field) { diff --git a/usr/local/www/diag_logs_ipsec.php b/usr/local/www/diag_logs_ipsec.php index 9de5494..039193b 100755 --- a/usr/local/www/diag_logs_ipsec.php +++ b/usr/local/www/diag_logs_ipsec.php @@ -73,7 +73,7 @@ if ($_POST['clear']) $ipsec_logarr = return_clog($ipsec_logfile, $nentries); -$pgtitle = array(gettext("Status"),gettext("System logs"),gettext("IPsec VPN")); +$pgtitle = array("Status","System logs","IPsec VPN"); include("head.inc"); ?> @@ -84,17 +84,17 @@ include("head.inc"); <td> <?php $tab_array = array(); - $tab_array[] = array(gettext("System"), false, "diag_logs.php"); - $tab_array[] = array(gettext("Firewall"), false, "diag_logs_filter.php"); - $tab_array[] = array(gettext("DHCP"), false, "diag_logs_dhcp.php"); - $tab_array[] = array(gettext("Portal Auth"), false, "diag_logs_auth.php"); - $tab_array[] = array(gettext("IPsec"), true, "diag_logs_ipsec.php"); - $tab_array[] = array(gettext("PPP"), false, "diag_logs_ppp.php"); - $tab_array[] = array(gettext("VPN"), false, "diag_logs_vpn.php"); - $tab_array[] = array(gettext("Load Balancer"), false, "diag_logs_relayd.php"); - $tab_array[] = array(gettext("OpenVPN"), false, "diag_logs_openvpn.php"); - $tab_array[] = array(gettext("OpenNTPD"), false, "diag_logs_ntpd.php"); - $tab_array[] = array(gettext("Settings"), false, "diag_logs_settings.php"); + $tab_array[] = array("System", false, "diag_logs.php"); + $tab_array[] = array("Firewall", false, "diag_logs_filter.php"); + $tab_array[] = array("DHCP", false, "diag_logs_dhcp.php"); + $tab_array[] = array("Portal Auth", false, "diag_logs_auth.php"); + $tab_array[] = array("IPsec", true, "diag_logs_ipsec.php"); + $tab_array[] = array("PPP", false, "diag_logs_ppp.php"); + $tab_array[] = array("VPN", false, "diag_logs_vpn.php"); + $tab_array[] = array("Load Balancer", false, "diag_logs_relayd.php"); + $tab_array[] = array("OpenVPN", false, "diag_logs_openvpn.php"); + $tab_array[] = array("OpenNTPD", false, "diag_logs_ntpd.php"); + $tab_array[] = array("Settings", false, "diag_logs_settings.php"); display_top_tabs($tab_array); ?> </td> @@ -104,7 +104,7 @@ include("head.inc"); <div id="mainarea"> <table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> - <td colspan="2" class="listtopic"><?php printf(gettext("Last %s IPsec log entries"),$nentries);?></td> + <td colspan="2" class="listtopic">Last <?=$nentries;?> IPsec log entries</td> </tr> <?php foreach($ipsec_logarr as $logent){ @@ -116,7 +116,7 @@ include("head.inc"); $logent = preg_replace($search, $replace, $logent); } else { $searchs = "/(racoon: )([A-Z:].*?)([0-9].+\.[0-9].+.[0-9].+.[0-9].+\[[0-9].+\])(.*)/i"; - $replaces = "$1<strong><font color=red>[".gettext("Unknown Gateway/Dynamic")."]</font></strong>: $2$3$4"; + $replaces = "$1<strong><font color=red>[Unknown Gateway/Dynamic]</font></strong>: $2$3$4"; $logent = preg_replace($searchs, $replaces, $logent); } $logent = preg_split("/\s+/", $logent, 6); diff --git a/usr/local/www/diag_logs_ntpd.php b/usr/local/www/diag_logs_ntpd.php index 588c0e2..d168f70 100644 --- a/usr/local/www/diag_logs_ntpd.php +++ b/usr/local/www/diag_logs_ntpd.php @@ -51,7 +51,7 @@ if (!$nentries) if ($_POST['clear']) clear_log_file($ntpd_logfile); -$pgtitle = array(gettext("Status"),gettext("System logs"),gettext("OpenNTPD")); +$pgtitle = array("Status","System logs","OpenNTPD"); include("head.inc"); ?> @@ -62,17 +62,17 @@ include("head.inc"); <tr><td> <?php $tab_array = array(); - $tab_array[] = array(gettext("System"), false, "diag_logs.php"); - $tab_array[] = array(gettext("Firewall"), false, "diag_logs_filter.php"); - $tab_array[] = array(gettext("DHCP"), false, "diag_logs_dhcp.php"); - $tab_array[] = array(gettext("Portal Auth"), false, "diag_logs_auth.php"); - $tab_array[] = array(gettext("IPsec"), false, "diag_logs_ipsec.php"); - $tab_array[] = array(gettext("PPP"), false, "diag_logs_ppp.php"); - $tab_array[] = array(gettext("VPN"), false, "diag_logs_vpn.php"); - $tab_array[] = array(gettext("Load Balancer"), false, "diag_logs_relayd.php"); - $tab_array[] = array(gettext("OpenVPN"), false, "diag_logs_openvpn.php"); - $tab_array[] = array(gettext("OpenNTPD"), true, "diag_logs_ntpd.php"); - $tab_array[] = array(gettext("Settings"), false, "diag_logs_settings.php"); + $tab_array[] = array("System", false, "diag_logs.php"); + $tab_array[] = array("Firewall", false, "diag_logs_filter.php"); + $tab_array[] = array("DHCP", false, "diag_logs_dhcp.php"); + $tab_array[] = array("Portal Auth", false, "diag_logs_auth.php"); + $tab_array[] = array("IPsec", false, "diag_logs_ipsec.php"); + $tab_array[] = array("PPP", false, "diag_logs_ppp.php"); + $tab_array[] = array("VPN", false, "diag_logs_vpn.php"); + $tab_array[] = array("Load Balancer", false, "diag_logs_relayd.php"); + $tab_array[] = array("OpenVPN", false, "diag_logs_openvpn.php"); + $tab_array[] = array("OpenNTPD", true, "diag_logs_ntpd.php"); + $tab_array[] = array("Settings", false, "diag_logs_settings.php"); display_top_tabs($tab_array); ?> </td></tr> @@ -82,7 +82,7 @@ include("head.inc"); <table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td colspan="2" class="listtopic"> - <?php printf(gettext("Last %s OpenNTPD log entries"), $nentries);?></td> + Last <?=$nentries;?> OpenNTPD log entries</td> </tr> <?php dump_clog($ntpd_logfile, $nentries); ?> <tr><td><br> diff --git a/usr/local/www/diag_logs_openvpn.php b/usr/local/www/diag_logs_openvpn.php index f052ad9..aa50856 100644 --- a/usr/local/www/diag_logs_openvpn.php +++ b/usr/local/www/diag_logs_openvpn.php @@ -42,7 +42,7 @@ ##|*MATCH=diag_logs_openvpn.php* ##|-PRIV -$pgtitle = array(gettext("Status"),gettext("System logs"),gettext("OpenVPN")); +$pgtitle = array("Status","System logs","OpenVPN"); require("guiconfig.inc"); require_once("vpn.inc"); @@ -66,17 +66,17 @@ include("head.inc"); <td> <?php $tab_array = array(); - $tab_array[] = array(gettext("System"), false, "diag_logs.php"); - $tab_array[] = array(gettext("Firewall"), false, "diag_logs_filter.php"); - $tab_array[] = array(gettext("DHCP"), false, "diag_logs_dhcp.php"); - $tab_array[] = array(gettext("Portal Auth"), false, "diag_logs_auth.php"); - $tab_array[] = array(gettext("IPsec"), false, "diag_logs_ipsec.php"); - $tab_array[] = array(gettext("PPP"), false, "diag_logs_ppp.php"); - $tab_array[] = array(gettext("VPN"), false, "diag_logs_vpn.php"); - $tab_array[] = array(gettext("Load Balancer"), false, "diag_logs_relayd.php"); - $tab_array[] = array(gettext("OpenVPN"), true, "diag_logs_openvpn.php"); - $tab_array[] = array(gettext("OpenNTPD"), false, "diag_logs_ntpd.php"); - $tab_array[] = array(gettext("Settings"), false, "diag_logs_settings.php"); + $tab_array[] = array("System", false, "diag_logs.php"); + $tab_array[] = array("Firewall", false, "diag_logs_filter.php"); + $tab_array[] = array("DHCP", false, "diag_logs_dhcp.php"); + $tab_array[] = array("Portal Auth", false, "diag_logs_auth.php"); + $tab_array[] = array("IPsec", false, "diag_logs_ipsec.php"); + $tab_array[] = array("PPP", false, "diag_logs_ppp.php"); + $tab_array[] = array("VPN", false, "diag_logs_vpn.php"); + $tab_array[] = array("Load Balancer", false, "diag_logs_relayd.php"); + $tab_array[] = array("OpenVPN", true, "diag_logs_openvpn.php"); + $tab_array[] = array("OpenNTPD", false, "diag_logs_ntpd.php"); + $tab_array[] = array("Settings", false, "diag_logs_settings.php"); display_top_tabs($tab_array); ?> </td> @@ -86,7 +86,7 @@ include("head.inc"); <div id="mainarea"> <table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> - <td colspan="2" class="listtopic"><?php printf(gettext("Last %s OpenVPN log entries"),$nentries)?></td> + <td colspan="2" class="listtopic">Last <?=$nentries;?> OpenVPN log entries</td> </tr> <?php dump_clog($openvpn_logfile, $nentries); ?> <tr> diff --git a/usr/local/www/diag_logs_ppp.php b/usr/local/www/diag_logs_ppp.php index 52eb40b..470d33d 100755 --- a/usr/local/www/diag_logs_ppp.php +++ b/usr/local/www/diag_logs_ppp.php @@ -56,7 +56,7 @@ if ($_POST['clear']) $ppp_logarr = return_clog($ppp_logfile, $nentries); -$pgtitle = array(gettext("Status"),gettext("System logs"),gettext("PPP")); +$pgtitle = array("Status","System logs","PPP"); include("head.inc"); ?> @@ -67,17 +67,17 @@ include("head.inc"); <td> <?php $tab_array = array(); - $tab_array[] = array(gettext("System"), false, "diag_logs.php"); - $tab_array[] = array(gettext("Firewall"), false, "diag_logs_filter.php"); - $tab_array[] = array(gettext("DHCP"), false, "diag_logs_dhcp.php"); - $tab_array[] = array(gettext("Portal Auth"), false, "diag_logs_auth.php"); - $tab_array[] = array(gettext("IPsec"), false, "diag_logs_ipsec.php"); - $tab_array[] = array(gettext("PPP"), true, "diag_logs_ppp.php"); - $tab_array[] = array(gettext("VPN"), false, "diag_logs_vpn.php"); - $tab_array[] = array(gettext("Load Balancer"), false, "diag_logs_relayd.php"); - $tab_array[] = array(gettext("OpenVPN"), false, "diag_logs_openvpn.php"); - $tab_array[] = array(gettext("OpenNTPD"), false, "diag_logs_ntpd.php"); - $tab_array[] = array(gettext("Settings"), false, "diag_logs_settings.php"); + $tab_array[] = array("System", false, "diag_logs.php"); + $tab_array[] = array("Firewall", false, "diag_logs_filter.php"); + $tab_array[] = array("DHCP", false, "diag_logs_dhcp.php"); + $tab_array[] = array("Portal Auth", false, "diag_logs_auth.php"); + $tab_array[] = array("IPsec", false, "diag_logs_ipsec.php"); + $tab_array[] = array("PPP", true, "diag_logs_ppp.php"); + $tab_array[] = array("VPN", false, "diag_logs_vpn.php"); + $tab_array[] = array("Load Balancer", false, "diag_logs_relayd.php"); + $tab_array[] = array("OpenVPN", false, "diag_logs_openvpn.php"); + $tab_array[] = array("OpenNTPD", false, "diag_logs_ntpd.php"); + $tab_array[] = array("Settings", false, "diag_logs_settings.php"); display_top_tabs($tab_array); ?> </td> @@ -87,7 +87,7 @@ include("head.inc"); <div id="mainarea"> <table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> - <td colspan="2" class="listtopic"><?php printf (gettext("Last <?=$nentries;?> PPP log entries"),$nentries);?></td> + <td colspan="2" class="listtopic">Last <?=$nentries;?> PPP log entries</td> </tr> <?php foreach($ppp_logarr as $logent){ @@ -95,7 +95,7 @@ include("head.inc"); $logent = preg_replace($search, $replace, $logent); } else { $searchs = "/(racoon: )([A-Z:].*?)([0-9].+\.[0-9].+.[0-9].+.[0-9].+\[[0-9].+\])(.*)/i"; - $replaces = "$1<strong><font color=red>[".gettext("Unknown Gateway/Dynamic")."]</font></strong>: $2$3$4"; + $replaces = "$1<strong><font color=red>[Unknown Gateway/Dynamic]</font></strong>: $2$3$4"; $logent = preg_replace($searchs, $replaces, $logent); } $logent = preg_split("/\s+/", $logent, 6); diff --git a/usr/local/www/diag_logs_relayd.php b/usr/local/www/diag_logs_relayd.php index 8ce35b8..f267c74 100755 --- a/usr/local/www/diag_logs_relayd.php +++ b/usr/local/www/diag_logs_relayd.php @@ -52,7 +52,7 @@ if (!$nentries) if ($_POST['clear']) clear_log_file($relayd_logfile); -$pgtitle = array(gettext("Status"),gettext("System logs"),gettext("Load Balancer")); +$pgtitle = array("Status","System logs","Load Balancer"); include("head.inc"); ?> @@ -63,17 +63,17 @@ include("head.inc"); <tr><td> <?php $tab_array = array(); - $tab_array[] = array(gettext("System"), false, "diag_logs.php"); - $tab_array[] = array(gettext("Firewall"), false, "diag_logs_filter.php"); - $tab_array[] = array(gettext("DHCP"), false, "diag_logs_dhcp.php"); - $tab_array[] = array(gettext("Portal Auth"), false, "diag_logs_auth.php"); - $tab_array[] = array(gettext("PPP"), false, "diag_logs_ppp.php"); - $tab_array[] = array(gettext("IPsec"), false, "diag_logs_ipsec.php"); - $tab_array[] = array(gettext("VPN"), false, "diag_logs_vpn.php"); - $tab_array[] = array(gettext("Load Balancer"), true, "diag_logs_relayd.php"); - $tab_array[] = array(gettext("OpenVPN"), false, "diag_logs_openvpn.php"); - $tab_array[] = array(gettext("OpenNTPD"), false, "diag_logs_ntpd.php"); - $tab_array[] = array(gettext("Settings"), false, "diag_logs_settings.php"); + $tab_array[] = array("System", false, "diag_logs.php"); + $tab_array[] = array("Firewall", false, "diag_logs_filter.php"); + $tab_array[] = array("DHCP", false, "diag_logs_dhcp.php"); + $tab_array[] = array("Portal Auth", false, "diag_logs_auth.php"); + $tab_array[] = array("PPP", false, "diag_logs_ppp.php"); + $tab_array[] = array("IPsec", false, "diag_logs_ipsec.php"); + $tab_array[] = array("VPN", false, "diag_logs_vpn.php"); + $tab_array[] = array("Load Balancer", true, "diag_logs_relayd.php"); + $tab_array[] = array("OpenVPN", false, "diag_logs_openvpn.php"); + $tab_array[] = array("OpenNTPD", false, "diag_logs_ntpd.php"); + $tab_array[] = array("Settings", false, "diag_logs_settings.php"); display_top_tabs($tab_array); ?> </td></tr> @@ -83,7 +83,7 @@ include("head.inc"); <table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td colspan="2" class="listtopic"> - <?php printf(gettext("Last %s Load Balancer log entries"),$nentries);?></td> + Last <?=$nentries;?> Load Balancer log entries</td> </tr> <?php dump_clog($relayd_logfile, $nentries); ?> <tr><td><br><form action="diag_logs_relayd.php" method="post"> diff --git a/usr/local/www/diag_logs_settings.php b/usr/local/www/diag_logs_settings.php index b86da2c..f2b7861 100755 --- a/usr/local/www/diag_logs_settings.php +++ b/usr/local/www/diag_logs_settings.php @@ -73,20 +73,20 @@ if ($_POST) { /* input validation */ if ($_POST['enable'] && !is_ipaddr($_POST['remoteserver'])) { - $input_errors[] = gettext("A valid IP address must be specified for remote syslog server #1."); + $input_errors[] = "A valid IP address must be specified for remote syslog server #1."; } if ($_POST['enable'] && $_POST['remoteserver2'] && !is_ipaddr($_POST['remoteserver2'])) { - $input_errors[] = gettext("A valid IP address must be specified for remote syslog server #2."); + $input_errors[] = "A valid IP address must be specified for remote syslog server #2."; } if ($_POST['enable'] && $_POST['remoteserver3'] && !is_ipaddr($_POST['remoteserver3'])) { - $input_errors[] = gettext("A valid IP address must be specified for remote syslog server #3."); + $input_errors[] = "A valid IP address must be specified for remote syslog server #3."; } if ($_POST['enable'] && !is_ipaddr($_POST['remoteserver'])) { - $input_errors[] = gettext("A valid IP address must be specified."); + $input_errors[] = "A valid IP address must be specified."; } if (($_POST['nentries'] < 5) || ($_POST['nentries'] > 2000)) { - $input_errors[] = gettext("Number of log entries to show must be between 5 and 2000."); + $input_errors[] = "Number of log entries to show must be between 5 and 2000."; } if (!$input_errors) { @@ -123,7 +123,7 @@ if ($_POST) { } } -$pgtitle = array(gettext("Status"), gettext("System logs"), gettext("Settings")); +$pgtitle = array("Status","System logs","Settings"); include("head.inc"); ?> @@ -166,17 +166,17 @@ function enable_change(enable_over) { <tr><td> <?php $tab_array = array(); - $tab_array[] = array(gettext("System"), false, "diag_logs.php"); - $tab_array[] = array(gettext("Firewall"), false, "diag_logs_filter.php"); - $tab_array[] = array(gettext("DHCP"), false, "diag_logs_dhcp.php"); - $tab_array[] = array(gettext("Portal Auth"), false, "diag_logs_auth.php"); - $tab_array[] = array(gettext("IPsec"), false, "diag_logs_ipsec.php"); - $tab_array[] = array(gettext("PPP"), false, "diag_logs_ppp.php"); - $tab_array[] = array(gettext("VPN"), false, "diag_logs_vpn.php"); - $tab_array[] = array(gettext("Load Balancer"), false, "diag_logs_relayd.php"); - $tab_array[] = array(gettext("OpenVPN"), false, "diag_logs_openvpn.php"); - $tab_array[] = array(gettext("OpenNTPD"), false, "diag_logs_ntpd.php"); - $tab_array[] = array(gettext("Settings"), true, "diag_logs_settings.php"); + $tab_array[] = array("System", false, "diag_logs.php"); + $tab_array[] = array("Firewall", false, "diag_logs_filter.php"); + $tab_array[] = array("DHCP", false, "diag_logs_dhcp.php"); + $tab_array[] = array("Portal Auth", false, "diag_logs_auth.php"); + $tab_array[] = array("IPsec", false, "diag_logs_ipsec.php"); + $tab_array[] = array("PPP", false, "diag_logs_ppp.php"); + $tab_array[] = array("VPN", false, "diag_logs_vpn.php"); + $tab_array[] = array("Load Balancer", false, "diag_logs_relayd.php"); + $tab_array[] = array("OpenVPN", false, "diag_logs_openvpn.php"); + $tab_array[] = array("OpenNTPD", false, "diag_logs_ntpd.php"); + $tab_array[] = array("Settings", true, "diag_logs_settings.php"); display_top_tabs($tab_array); ?> </td></tr> @@ -187,44 +187,46 @@ function enable_change(enable_over) { <tr> <td width="22%" valign="top" class="vtable"> </td> <td width="78%" class="vtable"> <input name="reverse" type="checkbox" id="reverse" value="yes" <?php if ($pconfig['reverse']) echo "checked"; ?>> - <strong><?=gettext("Show log entries in reverse order (newest entries on top)");?></strong></td> + <strong>Show log entries in reverse order (newest entries + on top)</strong></td> </tr> <tr> <td width="22%" valign="top" class="vtable"> </td> - <td width="78%" class="vtable"><?=gettext("Number of log entries to show") . ":"?> + <td width="78%" class="vtable">Number of log entries to + show: <input name="nentries" id="nentries" type="text" class="formfld unknown" size="4" value="<?=htmlspecialchars($pconfig['nentries']);?>"></td> </tr> <tr> <td valign="top" class="vtable"> </td> <td class="vtable"> <input name="logdefaultblock" type="checkbox" id="logdefaultblock" value="yes" <?php if ($pconfig['logdefaultblock']) echo "checked"; ?>> - <strong><?=gettext("Log packets blocked by the default rule");?></strong><br> - <?=gettext("Hint: packets that are blocked by the " . - "implicit default block rule will not be logged anymore " . - "if you uncheck this option. Per-rule logging options are not affected.");?></td> + <strong>Log packets blocked by the default rule</strong><br> + Hint: packets that are blocked by the + implicit default block rule will not be logged anymore + if you uncheck this option. Per-rule logging options are not affected.</td> </tr> <tr> <td valign="top" class="vtable"> </td> <td class="vtable"> <input name="rawfilter" type="checkbox" id="rawfilter" value="yes" <?php if ($pconfig['rawfilter']) echo "checked"; ?>> - <strong><?=gettext("Show raw filter logs");?></strong><br> - <?=gettext("Hint: If this is checked, filter logs are shown as generated by the packet filter, without any formatting. This will reveal more detailed information.");?></td> + <strong>Show raw filter logs</strong><br> + Hint: If this is checked, filter logs are shown as generated by the packet filter, without any formatting. This will reveal more detailed information. </td> </tr> <tr> <td width="22%" valign="top" class="vtable"> </td> <td width="78%" class="vtable"> <input name="disablelocallogging" type="checkbox" id="disablelocallogging" value="yes" <?php if ($pconfig['disablelocallogging']) echo "checked"; ?> onClick="enable_change(false)"> - <strong><?=gettext("Disable writing log files to the local RAM disk");?></strong></td> + <strong>Disable writing log files to the local RAM disk</strong></td> </tr> <tr> <td width="22%" valign="top" class="vtable"> </td> <td width="78%" class="vtable"> <input name="enable" type="checkbox" id="enable" value="yes" <?php if ($pconfig['enable']) echo "checked"; ?> onClick="enable_change(false)"> - <strong><?=gettext("Enable syslog'ing to remote syslog server");?></strong></td> + <strong>Enable syslog'ing to remote syslog server</strong></td> </tr> <tr> - <td width="22%" valign="top" class="vncell"><?=gettext("Remote syslog servers");?></td> + <td width="22%" valign="top" class="vncell">Remote syslog servers</td> <td width="78%" class="vtable"> <table> <tr> <td> - <?=gettext("Server") . " 1";?> + Server 1 </td> <td> <input name="remoteserver" id="remoteserver" type="text" class="formfld host" size="20" value="<?=htmlspecialchars($pconfig['remoteserver']);?>"> @@ -232,7 +234,7 @@ function enable_change(enable_over) { </tr> <tr> <td> - <?=gettext("Server") . " 2";?> + Server 2 </td> <td> <input name="remoteserver2" id="remoteserver2" type="text" class="formfld host" size="20" value="<?=htmlspecialchars($pconfig['remoteserver2']);?>"> @@ -240,7 +242,7 @@ function enable_change(enable_over) { </tr> <tr> <td> - <?=gettext("Server") . " 3";?> + Server 3 </td> <td> <input name="remoteserver3" id="remoteserver3" type="text" class="formfld host" size="20" value="<?=htmlspecialchars($pconfig['remoteserver3']);?>"> @@ -251,17 +253,17 @@ function enable_change(enable_over) { </td> <td> - <?=gettext("IP addresses of remote syslog servers");?> + IP addresses of remote syslog servers </td> </table> <input name="system" id="system" type="checkbox" value="yes" onclick="enable_change(false)" <?php if ($pconfig['system']) echo "checked"; ?>> - <?=gettext("system events");?><br> <input name="filter" id="filter" type="checkbox" value="yes" <?php if ($pconfig['filter']) echo "checked"; ?>> - <?=gettext("firewall events");?><br> <input name="dhcp" id="dhcp" type="checkbox" value="yes" <?php if ($pconfig['dhcp']) echo "checked"; ?>> - <?=gettext("DHCP service events");?><br> <input name="portalauth" id="portalauth" type="checkbox" value="yes" <?php if ($pconfig['portalauth']) echo "checked"; ?>> - <?=gettext("Portal Auth");?><br> <input name="vpn" id="vpn" type="checkbox" value="yes" <?php if ($pconfig['vpn']) echo "checked"; ?>> - <?=gettext("PPTP VPN events");?> + system events <br> <input name="filter" id="filter" type="checkbox" value="yes" <?php if ($pconfig['filter']) echo "checked"; ?>> + firewall events<br> <input name="dhcp" id="dhcp" type="checkbox" value="yes" <?php if ($pconfig['dhcp']) echo "checked"; ?>> + DHCP service events<br> <input name="portalauth" id="portalauth" type="checkbox" value="yes" <?php if ($pconfig['portalauth']) echo "checked"; ?>> + Portal Auth<br> <input name="vpn" id="vpn" type="checkbox" value="yes" <?php if ($pconfig['vpn']) echo "checked"; ?>> + PPTP VPN events <br> <input name="logall" id="logall" type="checkbox" value="yes" <?php if ($pconfig['logall']) echo "checked"; ?>> - <?=gettext("Everything");?> + Everything </td> </tr> <tr> @@ -271,10 +273,10 @@ function enable_change(enable_over) { </tr> <tr> <td width="22%" height="53" valign="top"> </td> - <td width="78%"><strong><span class="red"><?=gettext("Note") . ":"?></span></strong><br> - <?=gettext("syslog sends UDP datagrams to port 514 on the specified " . - "remote syslog server. Be sure to set syslogd on the " . - "remote server to accept syslog messages from");?> <?=$g['product_name']?>. + <td width="78%"><strong><span class="red">Note:</span></strong><br> + syslog sends UDP datagrams to port 514 on the specified + remote syslog server. Be sure to set syslogd on the + remote server to accept syslog messages from <?=$g['product_name']?>. </td> </tr> </table> diff --git a/usr/local/www/diag_logs_vpn.php b/usr/local/www/diag_logs_vpn.php index f4d20b2..83d0ecd 100755 --- a/usr/local/www/diag_logs_vpn.php +++ b/usr/local/www/diag_logs_vpn.php @@ -41,7 +41,7 @@ ##|*MATCH=diag_logs_vpn.php* ##|-PRIV -$pgtitle = array(gettext("Status"), gettext("System logs"), gettext("VPN")); +$pgtitle = array("Status","System logs","VPN"); require("guiconfig.inc"); require_once("vpn.inc"); @@ -98,17 +98,17 @@ include("head.inc"); <tr><td class="tabnavtbl"> <?php $tab_array = array(); - $tab_array[] = array(gettext("System"), false, "diag_logs.php"); - $tab_array[] = array(gettext("Firewall"), false, "diag_logs_filter.php"); - $tab_array[] = array(gettext("DHCP"), false, "diag_logs_dhcp.php"); - $tab_array[] = array(gettext("Portal Auth"), false, "diag_logs_auth.php"); - $tab_array[] = array(gettext("IPsec"), false, "diag_logs_ipsec.php"); - $tab_array[] = array(gettext("PPP"), false, "diag_logs_ppp.php"); - $tab_array[] = array(gettext("VPN"), true, "diag_logs_vpn.php"); - $tab_array[] = array(gettext("Load Balancer"), false, "diag_logs_relayd.php"); - $tab_array[] = array(gettext("OpenVPN"), false, "diag_logs_openvpn.php"); - $tab_array[] = array(gettext("OpenNTPD"), false, "diag_logs_ntpd.php"); - $tab_array[] = array(gettext("Settings"), false, "diag_logs_settings.php"); + $tab_array[] = array("System", false, "diag_logs.php"); + $tab_array[] = array("Firewall", false, "diag_logs_filter.php"); + $tab_array[] = array("DHCP", false, "diag_logs_dhcp.php"); + $tab_array[] = array("Portal Auth", false, "diag_logs_auth.php"); + $tab_array[] = array("IPsec", false, "diag_logs_ipsec.php"); + $tab_array[] = array("PPP", false, "diag_logs_ppp.php"); + $tab_array[] = array("VPN", true, "diag_logs_vpn.php"); + $tab_array[] = array("Load Balancer", false, "diag_logs_relayd.php"); + $tab_array[] = array("OpenVPN", false, "diag_logs_openvpn.php"); + $tab_array[] = array("OpenNTPD", false, "diag_logs_ntpd.php"); + $tab_array[] = array("Settings", false, "diag_logs_settings.php"); display_top_tabs($tab_array); ?> </td></tr> @@ -117,7 +117,7 @@ include("head.inc"); <form action="diag_logs_vpn.php" method="post"> <table width="100%" border="0" cellpadding="0" cellspacing="0"><tr> <td colspan="4" class="listtopic"> - <?=gettext("Choose which type of VPN you want to view.");?> + Choose which type of VPN you want to view. </td></tr><tr> <td colspan="4"> <?php $vpns = array("pptp" => "PPTP", "pppoe" => "PPPoE", "l2tp" => "L2TP"); @@ -131,13 +131,13 @@ include("head.inc"); </td></tr> <tr> <td colspan="4" class="listtopic"> - <?=gettext("Last");?> <?=$nentries;?> <?=$vpns[$vpntype];?> <?=gettext("VPN log entries");?></td> + Last <?=$nentries;?> <?=$vpns[$vpntype];?> VPN log entries</td> </tr> <tr> - <td class="listhdrr"><?=gettext("Time");?></td> - <td class="listhdrr"><?=gettext("Action");?></td> - <td class="listhdrr"><?=gettext("User");?></td> - <td class="listhdrr"><?=gettext("IP address");?></td> + <td class="listhdrr">Time</td> + <td class="listhdrr">Action</td> + <td class="listhdrr">User</td> + <td class="listhdrr">IP address</td> </tr> <?php dump_clog_vpn("/var/log/{$vpntype}.log", $nentries); ?> </table> diff --git a/usr/local/www/diag_nanobsd.php b/usr/local/www/diag_nanobsd.php index 3409a34..3e9bed1 100755 --- a/usr/local/www/diag_nanobsd.php +++ b/usr/local/www/diag_nanobsd.php @@ -46,7 +46,7 @@ ini_set('max_input_time', '9999'); require_once("guiconfig.inc"); require_once("config.inc"); -$pgtitle = array(gettext("Diagnostics"), gettext("NanoBSD")); +$pgtitle = array("Diagnostics","NanoBSD"); include("head.inc"); // Survey slice info @@ -70,12 +70,12 @@ if($_POST['bootslice']) { echo <<<EOF <div id="loading"> <img src="/themes/metallic/images/misc/loader.gif"> - gettext("Setting slice information, please wait...") + Setting slice information, please wait... <p/> </div> EOF; nanobsd_switch_boot_slice(); - $savemsg = gettext("The boot slice has been set to") . " " . nanobsd_get_active_slice(); + $savemsg = "The boot slice has been set to " . nanobsd_get_active_slice(); // Survey slice info nanobsd_detect_slice_info(); @@ -85,14 +85,14 @@ if($_POST['destslice']) { echo <<<EOF <div id="loading"> <img src="/themes/metallic/images/misc/loader.gif"> - gettext("Duplicating slice. Please wait, this will take a moment...") + Duplicating slice. Please wait, this will take a moment... <p/> </div> EOF; if(nanobsd_clone_slice($_POST['destslice'])) { - $savemsg = gettext("The slice has been duplicated.") . "<p/>" . gettext("If you would like to boot from this newly duplicated slice please set it using the bootup information area."); + $savemsg = "The slice has been duplicated.<p/>If you would like to boot from this newly duplicated slice please set it using the bootup information area."; } else { - $savemsg = gettext("There was an error while duplicating the slice. Operation aborted."); + $savemsg = "There was an error while duplicating the slice. Operation aborted."; } // Re-Survey slice info nanobsd_detect_slice_info(); @@ -113,28 +113,28 @@ if ($savemsg) <div class="tabcont"> <span class="vexpl"> <span class="red"> - <strong><?=gettext("NOTE") . ":"?> </strong> + <strong>NOTE: </strong> </span> - <?=gettext("The options on this page are intended for use by advanced users only.")?> + The options on this page are intended for use by advanced users only. <br/> </span> <p/> <table width="100%" border="0" cellpadding="6" cellspacing="0"> <tr> - <td colspan="2" valign="top" class="listtopic"><?=gettext("Bootup information");?></td> + <td colspan="2" valign="top" class="listtopic">Bootup information</td> </tr> <tr> - <td width="22%" valign="top" class="vncell"><?=gettext("NanoBSD Image size");?></td> + <td width="22%" valign="top" class="vncell">NanoBSD Image size</td> <td width="78%" class="vtable"> <?php echo $NANOBSD_SIZE; ?> </td> </tr> <tr> - <td width="22%" valign="top" class="vncell"><?=gettext("Bootup");?></td> + <td width="22%" valign="top" class="vncell">Bootup</td> <td width="78%" class="vtable"> <form action="diag_nanobsd.php" method="post" name="iform"> - <?=gettext("Bootup slice is currently");?>: <?php echo $ACTIVE_SLICE; ?> - <br/><br/><?=gettext("This will switch the bootup slice to the alternate slice.");?> + Bootup slice is currently: <?php echo $ACTIVE_SLICE; ?> + <br/><br/>This will switch the bootup slice to the alternate slice. <br/> <input type='hidden' name='bootslice' value='switch'> <input type='submit' value='Switch Slice'></form> @@ -144,20 +144,20 @@ if ($savemsg) <td colspan="2" valign="top" class=""> </td> </tr> <tr> - <td colspan="2" valign="top" class="listtopic"><?=gettext("Duplicate bootup slice to alternate");?></td> + <td colspan="2" valign="top" class="listtopic">Duplicate bootup slice to alternate</td> </tr> <tr> - <td width="22%" valign="top" class="vncell"><?=gettext("Duplicate bootup slice");?></td> + <td width="22%" valign="top" class="vncell">Duplicate bootup slice</td> <td width="78%" class="vtable"> <form action="diag_nanobsd.php" method="post" name="iform"> - <?=gettext("Destination slice");?>: + Destination slice: <select name='destslice'> <option value='<?php echo $COMPLETE_PATH; ?>'> <?php echo "{$COMPLETE_BOOT_PATH} -> {$TOFLASH}"; ?> </option> </select> <br/> - <?=gettext("This will duplicate the bootup slice to the alternate slice. Use this if you would like to duplicate the known good working boot partition to the alternate.");?> + This will duplicate the bootup slice to the alternate slice. Use this if you would like to duplicate the known good working boot partition to the alternate. </td> </tr> <tr> @@ -168,10 +168,10 @@ if ($savemsg) <td colspan="2" valign="top" class=""> </td> </tr> <tr> - <td colspan="2" valign="top" class="listtopic"><?=gettext("View upgrade log");?></td> + <td colspan="2" valign="top" class="listtopic">View upgrade log</td> </tr> <tr> - <td width="22%" valign="top" class="vncell"><?=gettext("View previous upgrade log");?></td> + <td width="22%" valign="top" class="vncell">View previous upgrade log</td> <td width="78%" class="vtable"> <?php if($_POST['viewupgradelog']) { diff --git a/usr/local/www/diag_overload_tables.php b/usr/local/www/diag_overload_tables.php index 4bb470d..235e868 100644 --- a/usr/local/www/diag_overload_tables.php +++ b/usr/local/www/diag_overload_tables.php @@ -41,7 +41,7 @@ ##|*MATCH=diag_overload_tables.php* ##|-PRIV -$pgtitle = array(gettext("Diagnostics"), gettext("Overload tables")); +$pgtitle = array("Diagnostics", "Overload tables"); require_once("guiconfig.inc"); @@ -96,7 +96,7 @@ include("fbegin.inc"); } </script> -<?=gettext("Table");?>: +Table: <select id='type' onChange='method_change($F("type"));' name='type'> <option name='<?=$tablename?>' value='<?=$tablename?>'><?=$tablename?></option> <option name='virusprot' value='virusprot'>virusprot</option> @@ -107,7 +107,7 @@ include("fbegin.inc"); <table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> - <td class="listhdrr"><?=gettext("IP Address");?></td> + <td class="listhdrr">IP Address</td> </tr> <?php $count = 0; foreach($entries as $entryA): ?> <?php $entry = trim($entryA); ?> @@ -124,14 +124,14 @@ include("fbegin.inc"); <?php $count++; endforeach; ?> <?php if($count == 0) - echo "<tr><td>" . gettext("No entries exist in this table.") . "</td></tr>"; + echo "<tr><td>No entries exist in this table.</td></tr>"; ?> </table> <?php if($count > 0) - echo "<p/>" . gettext("Delete") . " <a href='diag_overload_tables.php?deleteall=true&type={$tablename}'>" . gettext("all") . "</a> " . gettext("entries in this table."); + echo "<p/>Delete <a href='diag_overload_tables.php?deleteall=true&type={$tablename}'>all</a> entries in this table." ?> diff --git a/usr/local/www/diag_packet_capture.php b/usr/local/www/diag_packet_capture.php index e49d969..68248ea 100644 --- a/usr/local/www/diag_packet_capture.php +++ b/usr/local/www/diag_packet_capture.php @@ -35,7 +35,7 @@ ##|*MATCH=diag_packet_capture.php* ##|-PRIV -$pgtitle = array(gettext("Diagnostics"), gettext("Packet Capture")); +$pgtitle = array("Diagnostics", "Packet Capture"); require_once("guiconfig.inc"); require_once("pfsense-utils.inc"); @@ -64,14 +64,14 @@ if ($_POST) { } if ($_POST['startbtn'] != "" ) { - $action = gettext("Start"); + $action = "Start"; //delete previous packet capture if it exists if (file_exists($fp.$fn)) unlink ($fp.$fn); } elseif ($_POST['stopbtn']!= "") { - $action = gettext("Stop"); + $action = "Stop"; $processes_running = trim(shell_exec('/bin/ps axw -O pid= | /usr/bin/grep tcpdump | /usr/bin/grep $fn | /usr/bin/grep -v pflog')); //explode processes into an array, (delimiter is new line) @@ -95,6 +95,7 @@ if ($_POST) { } else { $do_tcpdump = false; } +$pgtitle = "Diagnostics: Packet Capture"; include("head.inc"); ?> <body link="#000000" vlink="#0000CC" alink="#0000CC"> @@ -109,10 +110,10 @@ include("fbegin.inc"); <form action="diag_packet_capture.php" method="post" name="iform" id="iform"> <table width="100%" border="0" cellpadding="6" cellspacing="0"> <tr> - <td colspan="2" valign="top" class="listtopic"><?=gettext("Packet capture");?></td> + <td colspan="2" valign="top" class="listtopic">Packet capture</td> </tr> <tr> - <td width="17%" valign="top" class="vncellreq"><?=gettext("Interface");?></td> + <td width="17%" valign="top" class="vncellreq">Interface</td> <td width="83%" class="vtable"> <select name="interface"> <?php @@ -124,58 +125,56 @@ include("fbegin.inc"); </option> <?php endforeach;?> </select> - <br/><?=gettext("Select the interface the traffic will be passing through. Typically this will be the WAN interface.");?> + <br/>Select the interface the traffic will be passing through. Typically this will be the WAN interface. </td> </tr> <tr> - <td width="17%" valign="top" class="vncellreq"><?=gettext("Host Address");?></td> + <td width="17%" valign="top" class="vncellreq">Host Address</td> <td width="83%" class="vtable"> <input name="host" type="text" class="formfld host" id="host" size="20" value="<?=htmlspecialchars($host);?>"> - <br/><?=gettext("This value is either the Source or Destination IP address. The packet capture will look for this address in either field.");?> - <br/><?=gettext("This value can be a domain name or IP address.");?> - <br/><?=gettext("If you leave this field blank, all packets on the specified interface will be captured. ");?> + <br/>This value is either the Source or Destination IP address. The packet capture will look for this address in either field. + <br/>This value can be a domain name or IP address. + <br/>If you leave this field blank, all packets on the specified interface will be captured. </td> </tr> <tr> - <td width="17%" valign="top" class="vncellreq"><?=gettext("Port");?></td> + <td width="17%" valign="top" class="vncellreq">Port</td> <td width="83%" class="vtable"> <input name="port" type="text" class="formfld unknown" id="port" size="5" value="<?=$port;?>"> - <br/><?=gettext("The port can be either the source or destination port. The packet capture will look for this port in either field.");?> - <br/><?=gettext("Leave blank if you do not want to filter by port.");?> + <br/>The port can be either the source or destination port. The packet capture will look for this port in either field. + <br/>Leave blank if you do not want to filter by port. </td> </tr> <tr> - <td width="17%" valign="top" class="vncellreq"><?=gettext("Packet Length");?></td> + <td width="17%" valign="top" class="vncellreq">Packet Length</td> <td width="83%" class="vtable"> <input name="snaplen" type="text" class="formfld unknown" id="snaplen" size="5" value="<?=$snaplen;?>"> - <br/><?=gettext("The Packet length is the number of bytes the packet will capture for each payload. Default value is 1500.");?> + <br/>The Packet length is the number of bytes the packet will capture for each payload. Default value is 1500. </td> </tr> <tr> - <td width="17%" valign="top" class="vncellreq"><?=gettext("Count");?></td> + <td width="17%" valign="top" class="vncellreq">Count</td> <td width="83%" class="vtable"> <input name="count" type="text" class="formfld unknown" id="count" size="5" value="<?=$count;?>"> - <br/><?=gettext("This is the number of packets the packet capture will grab. Default value is 100.") . "<br/>" . gettext("Enter 0 (zero) for no count limit.");?> + <br/>This is the number of packets the packet capture will grab. Default value is 100. <br/>Enter 0 (zero) for no count limit. </tr> <tr> - <td width="17%" valign="top" class="vncellreq"><?=gettext("Level of Detail");?></td> + <td width="17%" valign="top" class="vncellreq">Level of Detail</td> <td width="83%" class="vtable"> <select name="detail" type="text" class="formselect" id="detail" size="1"> - <option value="-q" <?php if ($detail == "-q") echo "selected"; ?>><?=gettext("Normal");?></option> - <option value="-v" <?php if ($detail == "-v") echo "selected"; ?>><?=gettext("Medium");?></option> - <option value="-vv" <?php if ($detail == "-vv") echo "selected"; ?>><?=gettext("High");?></option> - <option value="-vv -e" <?php if ($detail == "-vv -e") echo "selected"; ?>><?=gettext("Full");?></option> + <option value="-q" <?php if ($detail == "-q") echo "selected"; ?>>Normal</option> + <option value="-v" <?php if ($detail == "-v") echo "selected"; ?>>Medium</option> + <option value="-vv" <?php if ($detail == "-vv") echo "selected"; ?>>High</option> + <option value="-vv -e" <?php if ($detail == "-vv -e") echo "selected"; ?>>Full</option> </select> - <br/><?=gettext("This is the level of detail that will be displayed after hitting 'Stop' when the packets have been captured.") . "<br/><b>" . - gettext("Note") . ":</b> " . - gettext("This option does not affect the level of detail when downloading the packet capture.");?> + <br/>This is the level of detail that will be displayed after hitting 'Stop' when the packets have been captured. <br/><b>Note:</b> This option does not affect the level of detail when downloading the packet capture. </tr> <tr> - <td width="17%" valign="top" class="vncellreq"><?=gettext("Reverse DNS Lookup");?></td> + <td width="17%" valign="top" class="vncellreq">Reverse DNS Lookup</td> <td width="83%" class="vtable"> <input name="dnsquery" type="checkbox"<?php if($_POST['dnsquery']) echo " CHECKED"; ?>> - <br/><?=gettext("This check box will cause the packet capture to perform a reverse DNS lookup associated with all IP addresses.");?> - <br/><b><?=gettext("Note");?>: </b><?=gettext("This option can cause delays for large packet captures.");?> + <br/>This check box will cause the packet capture to perform a reverse DNS lookup associated with all IP addresses. + <br/><b>Note: </b>This option can cause delays for large packet captures. </td> </tr> <tr> @@ -191,14 +190,14 @@ include("fbegin.inc"); if ($processcheck != false) $processisrunning = true; - if (($action == gettext("Stop") or $action == "") and $processisrunning != true) - echo "<input type=\"submit\" name=\"startbtn\" value=\"" . gettext("Start") . "\"> "; + if (($action == "Stop" or $action == "") and $processisrunning != true) + echo "<input type=\"submit\" name=\"startbtn\" value=\"Start\"> "; else { - echo "<input type=\"submit\" name=\"stopbtn\" value=\"" . gettext("Stop") . "\"> "; + echo "<input type=\"submit\" name=\"stopbtn\" value=\"Stop\"> "; } if (file_exists($fp.$fn) and $processisrunning != true) { - echo "<input type=\"submit\" name=\"downloadbtn\" value=\"" . gettext("Download Capture") . "\">"; - echo " (" . gettext("The packet capture file was last updated") . ": " . date("F jS, Y g:i:s a.", filemtime($fp.$fn)) . ")"; + echo "<input type=\"submit\" name=\"downloadbtn\" value=\"Download Capture\">"; + echo " (The packet capture file was last updated: " . date("F jS, Y g:i:s a.", filemtime($fp.$fn)) . ")"; } ?> </td> @@ -208,7 +207,7 @@ include("fbegin.inc"); <?php echo "<font face='terminal' size='2'>"; if ($processisrunning == true) - echo("<strong>" . gettext("Packet Capture is running.") . "</strong><br/>"); + echo("<strong>Packet Capture is running.</strong><br/>"); if ($do_tcpdump) { @@ -235,12 +234,12 @@ include("fbegin.inc"); $selectedif = convert_friendly_interface_to_real_interface_name($selectedif); - if ($action == gettext("Start")) { - echo("<strong>" . gettext("Packet Capture is running.") . "</strong><br/>"); + if ($action == "Start") { + echo("<strong>Packet Capture is running.</strong><br/>"); mwexec_bg ("/usr/sbin/tcpdump -i $selectedif $searchcount -s $packetlength -w $fp$fn $searchhost $searchport"); } else { //action = stop - echo("<strong>" . gettext("Packet Capture stopped.") . "<br/><br/>" . gettext("Packets Captured") . ":</strong><br/>"); + echo("<strong>Packet Capture stopped. <br/><br/>Packets Captured:</strong><br/>"); ?> <textarea style="width:98%" name="code" rows="15" cols="66" wrap="off" readonly="readonly"> <?php diff --git a/usr/local/www/diag_patterns.php b/usr/local/www/diag_patterns.php index 09f5472..2e1d264 100755 --- a/usr/local/www/diag_patterns.php +++ b/usr/local/www/diag_patterns.php @@ -40,13 +40,13 @@ require("guiconfig.inc"); //Move the upload file to /usr/local/share/protocols (is_uploaded_file must use tmp_name as argument) -if (($_POST['submit'] == gettext("Upload")) && is_uploaded_file($_FILES['ulfile']['tmp_name'])) { +if (($_POST['submit'] == "Upload") && is_uploaded_file($_FILES['ulfile']['tmp_name'])) { if(fileExtension($_FILES['ulfile']['name'])) { move_uploaded_file($_FILES['ulfile']['tmp_name'], "/usr/local/share/protocols/" . $_FILES['ulfile']['name']); - $ulmsg = gettext("Uploaded file to") . " /usr/local/share/protocols/" . htmlentities($_FILES['ulfile']['name']); + $ulmsg = "Uploaded file to /usr/local/share/protocols/" . htmlentities($_FILES['ulfile']['name']); } else - $ulmsg = gettext("Warning: You must upload a file with .pat extension."); + $ulmsg = "Warning: You must upload a file with .pat extension."; } //Check if file has correct extension (.pat) @@ -55,7 +55,7 @@ function fileExtension($nameFile) { return ($format == ".pat"); } -$pgtitle = array(gettext("Diagnostics"), gettext("Add layer7 pattern")); +$pgtitle = array("Diagnostics","Add layer7 pattern"); include("head.inc"); ?> @@ -95,24 +95,24 @@ pre { </head> <body link="#0000CC" vlink="#0000CC" alink="#0000CC"> <?php include("fbegin.inc"); ?> -<p><strong><?=gettext("You can upload new layer7 patterns to your system!");?></strong></p> +<p><strong>You can upload new layer7 patterns to your system!</strong></p> <?php if ($ulmsg) echo "<p class=\"red\"><strong>" . $ulmsg . "</strong></p>\n"; ?> <div id="niftyOutter"> <form action="diag_patterns.php" method="POST" enctype="multipart/form-data" name="frmPattern"> <table> <tr> - <td colspan="2" valign="top" class="vnsepcell"><?=gettext("Upload");?></td> + <td colspan="2" valign="top" class="vnsepcell">Upload</td> </tr> <tr> - <td align="right"><?=gettext("File to upload");?>:</td> + <td align="right">File to upload:</td> <td valign="top" class="label"> <input name="ulfile" type="file" class="formfld file" id="ulfile"> </td></tr> <tr> <td valign="top"> </td> <td valign="top" class="label"> - <input name="submit" type="submit" class="button" id="upload" value="<?=gettext("Upload");?>"></td> + <input name="submit" type="submit" class="button" id="upload" value="Upload"></td> </tr> <tr> <td colspan="2" valign="top" height="16"></td> diff --git a/usr/local/www/diag_ping.php b/usr/local/www/diag_ping.php index a7bce2e..b5658f5 100755 --- a/usr/local/www/diag_ping.php +++ b/usr/local/www/diag_ping.php @@ -40,7 +40,7 @@ ##|*MATCH=diag_ping.php* ##|-PRIV -$pgtitle = array(gettext("Diagnostics"), "Ping"); +$pgtitle = array("Diagnostics", "Ping"); require("guiconfig.inc"); define('MAX_COUNT', 10); @@ -52,11 +52,11 @@ if ($_POST || $_REQUEST['host']) { /* input validation */ $reqdfields = explode(" ", "host count"); - $reqdfieldsn = array(",", gettext("Host"),gettext("Count")); + $reqdfieldsn = explode(",", "Host,Count"); do_input_validation($_REQUEST, $reqdfields, $reqdfieldsn, &$input_errors); if (($_REQUEST['count'] < 1) || ($_REQUEST['count'] > MAX_COUNT)) { - $input_errors[] = sprintf(gettext("Count must be between 1 and %s"), MAX_COUNT); + $input_errors[] = "Count must be between 1 and {MAX_COUNT}"; } if (!$input_errors) { @@ -103,7 +103,7 @@ include("head.inc"); ?> </td> </tr> <tr> - <td width="22%" valign="top" class="vncellreq"><?= gettext("Count"); ?></td> + <td width="22%" valign="top" class="vncellreq">Count</td> <td width="78%" class="vtable"> <select name="count" class="formfld" id="count"> <?php for ($i = 1; $i <= MAX_COUNT; $i++): ?> @@ -121,7 +121,7 @@ include("head.inc"); ?> <td valign="top" colspan="2"> <? if ($do_ping) { echo "<font face='terminal' size='2'>"; - echo "<strong>" . gettext("Ping output") . ":</strong><br>"); + echo("<strong>Ping output:</strong><br>"); echo('<pre>'); $ifaddr = get_interface_ip($interface); if ($ifaddr) diff --git a/usr/local/www/diag_pkglogs.php b/usr/local/www/diag_pkglogs.php index a7b65c9..d8f5436 100755 --- a/usr/local/www/diag_pkglogs.php +++ b/usr/local/www/diag_pkglogs.php @@ -77,7 +77,7 @@ if(!$apkg) { // If we aren't looking for a specific package, locate the first pa $i = $apkgid; } -$pgtitle = array(gettext("Status"),gettext("Package logs")); +$pgtitle = array("Status","Package logs"); include("head.inc"); ?> @@ -88,7 +88,7 @@ include("head.inc"); <ul id="tabnav"> <?php if($pkgwithlogging == false) { - print_info_box(gettext("No packages with logging facilities are currently installed.")); + print_info_box("No packages with logging facilities are currently installed."); echo '</ul></td></tr></table>'; include("fend.inc"); exit; @@ -112,7 +112,7 @@ include("head.inc"); <table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td colspan="2" class="listtopic"> - <?= gettext("Last") $nentries $curtab gettext("log entries") ?></td> + Last <?= $nentries ?> <?= $curtab ?> log entries</td> </tr> <?php $package =& $config['installedpackages']['package'][$apkgid]; diff --git a/usr/local/www/diag_resetstate.php b/usr/local/www/diag_resetstate.php index f56a65b..04819d0 100755 --- a/usr/local/www/diag_resetstate.php +++ b/usr/local/www/diag_resetstate.php @@ -51,11 +51,11 @@ if ($_POST) { filter_flush_state_table(); if ($savemsg) $savemsg .= " "; - $savemsg .= gettext("The state table has been flushed successfully."); + $savemsg .= "The state table has been flushed successfully."; } } -$pgtitle = array(gettext("Diagnostics"), gettext("Reset state")); +$pgtitle = array("Diagnostics","Reset state"); include("head.inc"); ?> @@ -68,8 +68,8 @@ include("head.inc"); <tr><td> <?php $tab_array = array(); - $tab_array[0] = array(gettext("States"), false, "diag_dump_states.php"); - $tab_array[1] = array(gettext("Reset States"), true, "diag_resetstate.php"); + $tab_array[0] = array("States", false, "diag_dump_states.php"); + $tab_array[1] = array("Reset States", true, "diag_resetstate.php"); display_top_tabs($tab_array); ?> </td></tr> @@ -80,27 +80,27 @@ include("head.inc"); <td width="22%" valign="top" class="vtable"> </td> <td width="78%" class="vtable"> <p> <input name="statetable" type="checkbox" id="statetable" value="yes" checked> - <strong><?= gettext("Firewall state table"); ?></strong><br> + <strong>Firewall state table</strong><br> <span class="vexpl"><br> - <?=gettext("Resetting the state tables will remove all entries from " . - "the corresponding tables. This means that all open connections " . - "will be broken and will have to be re-established. This " . - "may be necessary after making substantial changes to the " . - "firewall and/or NAT rules, especially if there are IP protocol " . - "mappings (e.g. for PPTP or IPv6) with open connections."); ?><br> + Resetting the state tables will remove all entries from + the corresponding tables. This means that all open connections + will be broken and will have to be re-established. This + may be necessary after making substantial changes to the + firewall and/or NAT rules, especially if there are IP protocol + mappings (e.g. for PPTP or IPv6) with open connections.<br> <br> - </span><span class="vexpl"><?=gettext("The firewall will normally leave " . - "the state tables intact when changing rules."); ?><br> + </span><span class="vexpl">The firewall will normally leave + the state tables intact when changing rules.<br> <br> - <?=gettext("NOTE: If you reset the firewall state table, the browser " . - "session may appear to be hung after clicking "Reset". " . - "Simply refresh the page to continue."); ?></span></p> + NOTE: If you reset the firewall state table, the browser + session may appear to be hung after clicking "Reset". + Simply refresh the page to continue.</span></p> </td> </tr> <tr> <td width="22%" valign="top"> </td> <td width="78%"> - <input name="Submit" type="submit" class="formbtn" value="<?=gettext("Reset"); ?>"> + <input name="Submit" type="submit" class="formbtn" value="Reset"> </td> </tr> </table> diff --git a/usr/local/www/diag_routes.php b/usr/local/www/diag_routes.php index efc9c69..1b136ab 100644 --- a/usr/local/www/diag_routes.php +++ b/usr/local/www/diag_routes.php @@ -33,6 +33,7 @@ pfSense_BUILDER_BINARIES: /usr/bin/netstat pfSense_MODULE: routing */ + ##|+PRIV ##|*IDENT=page-diagnostics-routingtables ##|*NAME=Diagnostics: Routing tables page @@ -42,7 +43,7 @@ include('guiconfig.inc'); -$pgtitle = array(gettext("Diagnostics"),gettext("Routing tables")); +$pgtitle = array("Diagnostics","Routing tables"); include('head.inc'); @@ -55,11 +56,11 @@ include('head.inc'); <table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="6"> <tr> -<td class="vncellreq" width="22%"><?=gettext("Name resolution");?></td> +<td class="vncellreq" width="22%">Name resolution</td> <td class="vtable" width="78%"> -<input type="checkbox" class="formfld" name="resolve" value="yes" <?php if ($_POST['resolve'] == 'yes') echo 'checked'; ?>><?=gettext("Enable");?></input> +<input type="checkbox" class="formfld" name="resolve" value="yes" <?php if ($_POST['resolve'] == 'yes') echo 'checked'; ?>> Enable</input> <br /> -<span class="expl"><?=gettext("Enable this to attempt to resolve names when displaying the tables.");?></span> +<span class="expl">Enable this to attempt to resolve names when displaying the tables.</span> </td> </tr> @@ -69,7 +70,7 @@ include('head.inc'); <input type="submit" class="formbtn" name="submit" value="Show" /> <br /> <br /> -<span class="vexpl"><span class="red"><strong><?=gettext("Note")?>:</strong></span><?=gettext("By enabling name resolution, the query should take a bit longer. You can stop it at"."any time by clicking the Stop button in your browser");?>.</span> +<span class="vexpl"><span class="red"><strong>Note:</strong></span> By enabling name resolution, the query should take a bit longer. You can stop it at any time by clicking the Stop button in your browser.</span> </td> </tr> diff --git a/usr/local/www/diag_showbogons.php b/usr/local/www/diag_showbogons.php index ed93403..e3f45b3 100644 --- a/usr/local/www/diag_showbogons.php +++ b/usr/local/www/diag_showbogons.php @@ -59,7 +59,7 @@ if($_POST['Download']) { } $bogons = file_get_contents(trim("/etc/bogons")); -$pgtitle = array(gettext("Diagnostics:")gettext("Show Bogons")); +$pgtitle = "Diagnostics: Show Bogons"; include("head.inc"); ?> @@ -87,7 +87,7 @@ pre { font-size: 1.15em; } <tr> <td> <font size="+1"> - <b><?=gettext("Currently loaded bogons table:");?></b><p/> + <b>Currently loaded bogons table:</b><p/> <pre> <?php echo $bogons; ?> </pre> @@ -103,7 +103,7 @@ pre { font-size: 1.15em; } </tr> </table> <p/> -<input type="submit" name="Download" value="<?=gettext("Download");?>"><?=gettext("latest bogon data.");?> +<input type="submit" name="Download" value="Download"> latest bogon data. </form> <?php include("fend.inc"); ?> </body> diff --git a/usr/local/www/diag_states_summary.php b/usr/local/www/diag_states_summary.php index 32290bb..40d064f 100644 --- a/usr/local/www/diag_states_summary.php +++ b/usr/local/www/diag_states_summary.php @@ -121,12 +121,12 @@ function print_summary_table($label, $iparr, $sort = TRUE) { ?> <h3><?php echo $label; ?></h3> <table class="tabcont" width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> - <td class="listhdrr"><?=gettext("IP");?></td> - <td class="listhdrr"><?=gettext("# States");?></td> - <td class="listhdrr"><?=gettext("Proto");?></td> - <td class="listhdrr"><?=gettext"(# States");?></td> - <td class="listhdrr"><?=gettext("Src Ports");?></td> - <td class="listhdrr"><?=gettext("Dst Ports");?></td> + <td class="listhdrr">IP</td> + <td class="listhdrr"># States</td> + <td class="listhdrr">Proto</td> + <td class="listhdrr"># States</td> + <td class="listhdrr">Src Ports</td> + <td class="listhdrr">Dst Ports</td> </tr> <?php if ($sort) uksort($iparr, "sort_by_ip"); @@ -156,16 +156,16 @@ function print_summary_table($label, $iparr, $sort = TRUE) { ?> <? } -$pgtitle = array(gettext("Diagnostics"),gettext("State Table Summary")); +$pgtitle = array("Diagnostics", "State Table Summary"); require_once("guiconfig.inc"); include("head.inc"); include("fbegin.inc"); -print_summary_table(gettext("By Source IP"), $srcipinfo); -print_summary_table(gettext("By Destination IP"), $dstipinfo); -print_summary_table(gettext("Total per IP"), $allipinfo); -print_summary_table(gettext("By IP Pair"), $pairipinfo, FALSE); +print_summary_table("By Source IP", $srcipinfo); +print_summary_table("By Destination IP", $dstipinfo); +print_summary_table("Total per IP", $allipinfo); +print_summary_table("By IP Pair", $pairipinfo, FALSE); ?> <?php include("fend.inc"); ?> diff --git a/usr/local/www/diag_system_activity.php b/usr/local/www/diag_system_activity.php index b94dc92..18e6842 100644 --- a/usr/local/www/diag_system_activity.php +++ b/usr/local/www/diag_system_activity.php @@ -43,7 +43,7 @@ require("guiconfig.inc"); $pfSversion = str_replace("\n", "", file_get_contents("/etc/version")); -$pgtitle = gettext("Diagnostics: System Activity"); +$pgtitle = "Diagnostics: System Activity"; if($_REQUEST['getactivity']) { $text = `/usr/bin/top -HS`; @@ -98,7 +98,7 @@ include("head.inc"); <table> <tr><td> <div name='cpuactivitydiv' id='cpuactivitydiv'> - <b><?=gettext("Gathering CPU activity, please wait...");?> + <b>Gathering CPU activity, please wait... </div> </td></tr> </table> diff --git a/usr/local/www/diag_system_pftop.php b/usr/local/www/diag_system_pftop.php index 4ff5cec..6dcee5c 100644 --- a/usr/local/www/diag_system_pftop.php +++ b/usr/local/www/diag_system_pftop.php @@ -42,7 +42,7 @@ require("guiconfig.inc"); $pfSversion = str_replace("\n", "", file_get_contents("/etc/version")); -$pgtitle = gettext("Diagnostics: PFTop"); +$pgtitle = "Diagnostics: PFTop"; if($_REQUEST['getactivity']) { if($_REQUEST['sorttype']) @@ -99,18 +99,18 @@ else Sort type: <select name='sorttype' id='sorttype' onChange='this.form.submit();'> <option value='<?=$sorttype?>'><?=$sorttype?></option> - <option value='age'><?=gettext("age");?></option> - <option value='bytes'><?=gettext("bytes");?></option> - <option value='dest'><?=gettext("dest");?></option> - <option value='dport'><?=gettext("dport");?></option> - <option value='exp'><?=gettext("exp");?></option> - <option value='none'><?=gettext("none");?></option> - <option value='peak'><?=gettext("peak");?></option> - <option value='pkt'><?=gettext("pkt");?></option> - <option value='rate'><?=gettext("rate");?></option> - <option value='size'><?=gettext("size");?></option> - <option value='sport'><?=gettext("sport");?></option> - <option value='src'><?=gettext("src");?></option> + <option value='age'>age</option> + <option value='bytes'>bytes</option> + <option value='dest'>dest</option> + <option value='dport'>dport</option> + <option value='exp'>exp</option> + <option value='none'>none</option> + <option value='peak'>peak</option> + <option value='pkt'>pkt</option> + <option value='rate'>rate</option> + <option value='size'>size</option> + <option value='sport'>sport</option> + <option value='src'>src</option> </select> <p/> <table width="100%" border="0" cellpadding="0" cellspacing="0"> @@ -123,7 +123,7 @@ else <table> <tr><td> <div name='cpuactivitydiv' id='cpuactivitydiv'> - <b><?=gettext("Gathering pfTOP activity, please wait...");?> + <b>Gathering pfTOP activity, please wait... </div> </td></tr> </table> diff --git a/usr/local/www/diag_traceroute.php b/usr/local/www/diag_traceroute.php index 75ffadf..7f30bbe 100755 --- a/usr/local/www/diag_traceroute.php +++ b/usr/local/www/diag_traceroute.php @@ -42,7 +42,7 @@ require("guiconfig.inc"); -$pgtitle = array(gettext("Diagnostics"),gettext("Traceroute")); +$pgtitle = array("Diagnostics","Traceroute"); include("head.inc"); ?> @@ -59,11 +59,11 @@ if ($_POST || $_REQUEST['host']) { /* input validation */ $reqdfields = explode(" ", "host ttl"); - $reqdfieldsn = array(gettext("Host"),gettext("ttl")); + $reqdfieldsn = explode(",", "Host,ttl"); do_input_validation($_REQUEST, $reqdfields, $reqdfieldsn, &$input_errors); if (($_REQUEST['ttl'] < 1) || ($_REQUEST['ttl'] > MAX_TTL)) { - $input_errors[] = sprintf(gettext("Maximum number of hops must be between 1 and '%s'", MAX_TLL); + $input_errors[] = "Maximum number of hops must be between 1 and {MAX_TTL}"; } if (!$input_errors) { @@ -83,15 +83,15 @@ if (!isset($do_traceroute)) { <form action="diag_traceroute.php" method="post" name="iform" id="iform"> <table width="100%" border="0" cellpadding="6" cellspacing="0"> <tr> - <td colspan="2" valign="top" class="listtopic"><?=gettext("Traceroute");?></td> + <td colspan="2" valign="top" class="listtopic">Traceroute</td> </tr> <tr> - <td width="22%" valign="top" class="vncellreq"><?=gettext("Host");?></td> + <td width="22%" valign="top" class="vncellreq">Host</td> <td width="78%" class="vtable"> <?=$mandfldhtml;?><input name="host" type="text" class="formfld" id="host" size="20" value="<?=htmlspecialchars($host);?>"></td> </tr> <tr> - <td width="22%" valign="top" class="vncellreq"><?=gettext("Maximum number of hops");?></td> + <td width="22%" valign="top" class="vncellreq">Maximum number of hops</td> <td width="78%" class="vtable"> <select name="ttl" class="formfld" id="ttl"> <?php for ($i = 1; $i <= MAX_TTL; $i++): ?> @@ -101,7 +101,7 @@ if (!isset($do_traceroute)) { </tr> <tr> - <td width="22%" valign="top" class="vncellreq"><?=gettext("Use ICMP");?></td> + <td width="22%" valign="top" class="vncellreq">Use ICMP</td> <td width="78%" class="vtable"> <input name="useicmp" type="checkbox"<?php if($_REQUEST['useicmp']) echo " CHECKED"; ?>> </td> @@ -109,12 +109,12 @@ if (!isset($do_traceroute)) { <tr> <td width="22%" valign="top"> </td> <td width="78%"> - <input name="Submit" type="submit" class="formbtn" value="<?=gettext("Traceroute");?>"> + <input name="Submit" type="submit" class="formbtn" value="Traceroute"> </td> </tr> <tr> <td valign="top" colspan="2"> - <p><span class="vexpl"><span class="red"><b><?=gettext("Note");?>:</b></span><?=gettext("Traceroute may take a while to complete.". "You may hit the Stop button on your browser at any time to see the progress of failed traceroutes.");?><p> + <p><span class="vexpl"><span class="red"><strong>Note: </strong></span> Traceroute may take a while to complete. You may hit the Stop button on your browser at any time to see the progress of failed traceroutes.<p> <? if ($do_traceroute) { echo "<font face='terminal' size='2'>"; echo("<br><strong>Traceroute output:</strong><br>"); @@ -133,7 +133,7 @@ if (!isset($do_traceroute)) { <tr> <td width="22%" valign="top"> </td> <td width="78%"> - <span class="vexpl"><b><?=gettext("Note");?>:</b></span><?=gettext("Multi-wan is not supported from this utility currently.");?> + <span class="vexpl"><strong>Note: </strong></span> Multi-wan is not supported from this utility currently. </td> </tr> </table> |