summaryrefslogtreecommitdiffstats
path: root/usr/local/www
diff options
context:
space:
mode:
Diffstat (limited to 'usr/local/www')
-rwxr-xr-xusr/local/www/firewall_shaper_queues.php14
-rwxr-xr-xusr/local/www/interfaces.php478
-rwxr-xr-xusr/local/www/interfaces_assign.php70
-rw-r--r--usr/local/www/interfaces_bridge.php36
-rw-r--r--usr/local/www/interfaces_bridge_edit.php204
-rw-r--r--usr/local/www/interfaces_gif.php36
-rw-r--r--usr/local/www/interfaces_gif_edit.php46
-rw-r--r--usr/local/www/interfaces_gre.php35
-rw-r--r--usr/local/www/interfaces_gre_edit.php55
-rwxr-xr-xusr/local/www/interfaces_groups.php37
-rwxr-xr-xusr/local/www/interfaces_groups_edit.php30
-rw-r--r--usr/local/www/interfaces_lagg.php34
-rw-r--r--usr/local/www/interfaces_lagg_edit.php82
-rw-r--r--usr/local/www/interfaces_ppps.php33
-rw-r--r--usr/local/www/interfaces_ppps_edit.php94
-rwxr-xr-xusr/local/www/interfaces_qinq.php39
-rwxr-xr-xusr/local/www/interfaces_qinq_edit.php54
-rwxr-xr-xusr/local/www/interfaces_vlan.php38
-rwxr-xr-xusr/local/www/interfaces_vlan_edit.php30
-rw-r--r--usr/local/www/interfaces_wireless.php36
-rw-r--r--usr/local/www/interfaces_wireless_edit.php34
-rwxr-xr-xusr/local/www/status.php10
22 files changed, 766 insertions, 759 deletions
diff --git a/usr/local/www/firewall_shaper_queues.php b/usr/local/www/firewall_shaper_queues.php
index ac3213a..35b6f21 100755
--- a/usr/local/www/firewall_shaper_queues.php
+++ b/usr/local/www/firewall_shaper_queues.php
@@ -169,7 +169,7 @@ if ($_POST['apply']) {
clear_subsystem_dirty('shaper');
}
-$pgtitle = gettext("Firewall: Shaper: By Queues View");
+$pgtitle = "Firewall: Shaper: By Queues View";
$statusurl = "status_queues.php";
include("head.inc");
@@ -184,17 +184,17 @@ include("head.inc");
<form action="firewall_shaper_queues.php" method="post" name="iform" id="iform">
<?php if ($savemsg) print_info_box($savemsg); ?>
<?php if (is_subsystem_dirty('shaper')): ?><p>
-<?php print_info_box_np(gettext("The traffic shaper configuration has been changed") . ".<br>" . gettext("You must apply the changes in order for them to take effect."));?><br>
+<?php print_info_box_np("The traffic shaper configuration has been changed.<br>You must apply the changes in order for them to take effect.");?><br>
<?php endif; ?>
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr><td>
<?php
$tab_array = array();
- $tab_array[0] = array(gettext("By Interface"), false, "firewall_shaper.php");
- $tab_array[1] = array(gettext("By Queue"), true, "firewall_shaper_queues.php");
- $tab_array[2] = array(gettext("Limiter"), false, "firewall_shaper_vinterface.php");
- $tab_array[3] = array(gettext("Layer7"), false, "firewall_shaper_layer7.php");
- $tab_array[4] = array(gettext("Wizards"), false, "firewall_shaper_wizards.php");
+ $tab_array[0] = array("By Interface", false, "firewall_shaper.php");
+ $tab_array[1] = array("By Queue", true, "firewall_shaper_queues.php");
+ $tab_array[2] = array("Limiter", false, "firewall_shaper_vinterface.php");
+ $tab_array[3] = array("Layer7", false, "firewall_shaper_layer7.php");
+ $tab_array[4] = array("Wizards", false, "firewall_shaper_wizards.php");
display_top_tabs($tab_array);
?>
</td></tr>
diff --git a/usr/local/www/interfaces.php b/usr/local/www/interfaces.php
index 340a6f8..888aa02 100755
--- a/usr/local/www/interfaces.php
+++ b/usr/local/www/interfaces.php
@@ -178,7 +178,7 @@ $pconfig['enable'] = isset($wancfg['enable']);
if (is_array($config['aliases']['alias'])) {
foreach($config['aliases']['alias'] as $alias) {
if($alias['name'] == $wancfg['descr']) {
- $input_errors[] = gettext("Sorry, an alias with the name {$wancfg['descr']} already exists.");
+ $input_errors[] = sprintf(gettext("Sorry, an alias with the name '%s' already exists."),$wancfg['descr']);
}
}
}
@@ -288,7 +288,7 @@ if (isset($wancfg['wireless'])) {
if ($_POST['apply']) {
unset($input_errors);
if (!is_subsystem_dirty('interfaces'))
- $intput_errors[] = "You have already applied your settings!";
+ $intput_errors[] = gettext("You have already applied your settings!");
else {
unlink_if_exists("{$g['tmp_path']}/config.cache");
clear_subsystem_dirty('interfaces');
@@ -300,7 +300,7 @@ if ($_POST['apply']) {
/* restart snmp so that it binds to correct address */
services_snmpd_configure();
if ($if == "lan")
- $savemsg = "The changes have been applied. You may need to correct your web browser's IP address.";
+ $savemsg = gettext("The changes have been applied. You may need to correct your web browser's IP address.");
/* sync filter configuration */
setup_gateways_monitor();
@@ -350,40 +350,40 @@ if ($_POST) {
/* description unique? */
foreach ($iflist as $ifent => $ifdescr) {
if ($if != $ifent && $ifdescr == $_POST['descr'])
- $input_errors[] = "An interface with the specified description already exists.";
+ $input_errors[] = gettext("An interface with the specified description already exists.");
}
/* input validation */
if (isset($config['dhcpd']) && isset($config['dhcpd'][$if]['enable']) && $_POST['type'] != "static")
- $input_errors[] = "The DHCP Server is active on this interface and it can be used only with a static IP configuration. Please disable the DHCP Server service on this interface first, then change the interface configuration.";
+ $input_errors[] = gettext("The DHCP Server is active on this interface and it can be used only with a static IP configuration. Please disable the DHCP Server service on this interface first, then change the interface configuration.");
switch($_POST['type']) {
case "static":
$reqdfields = explode(" ", "ipaddr subnet gateway");
- $reqdfieldsn = explode(",", "IP address,Subnet bit count,Gateway");
+ $reqdfieldsn = array(gettext("IP address"),gettext("Subnet bit count"),gettext("Gateway"));
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
break;
case "ppp":
$reqdfields = explode(" ", "port phone");
- $reqdfieldsn = explode(",", "Modem Port,Phone Number");
+ $reqdfieldsn = array(gettext("Modem Port"),gettext("Phone Number"));
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
break;
case "PPPoE":
if ($_POST['pppoe_dialondemand']) {
$reqdfields = explode(" ", "pppoe_username pppoe_password pppoe_dialondemand pppoe_idletimeout");
- $reqdfieldsn = explode(",", "PPPoE username,PPPoE password,Dial on demand,Idle timeout value");
+ $reqdfieldsn = array(gettext("PPPoE username"),gettext("PPPoE password"),gettext("Dial on demand"),gettext("Idle timeout value"));
} else {
$reqdfields = explode(" ", "pppoe_username pppoe_password");
- $reqdfieldsn = explode(",", "PPPoE username,PPPoE password");
+ $reqdfieldsn = array(gettext("PPPoE username"),gettext("PPPoE password"));
}
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
break;
case "PPTP":
if ($_POST['pptp_dialondemand']) {
$reqdfields = explode(" ", "pptp_username pptp_password pptp_local pptp_subnet pptp_remote pptp_dialondemand pptp_idletimeout");
- $reqdfieldsn = explode(",", "PPTP username,PPTP password,PPTP local IP address,PPTP subnet,PPTP remote IP address,Dial on demand,Idle timeout value");
+ $reqdfieldsn = array(gettext("PPTP username"),gettext("PPTP password"),gettext("PPTP local IP address"),gettext("PPTP subnet"),gettext("PPTP remote IP address"),gettext("Dial on demand"),gettext("Idle timeout value"));
} else {
$reqdfields = explode(" ", "pptp_username pptp_password pptp_local pptp_subnet pptp_remote");
- $reqdfieldsn = explode(",", "PPTP username,PPTP password,PPTP local IP address,PPTP subnet,PPTP remote IP address");
+ $reqdfieldsn = array(gettext("PPTP username"),gettext("PPTP password"),gettext("PPTP local IP address"),gettext("PPTP subnet"),gettext("PPTP remote IP address"));
}
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
break;
@@ -392,13 +392,13 @@ if ($_POST) {
/* normalize MAC addresses - lowercase and convert Windows-ized hyphenated MACs to colon delimited */
$_POST['spoofmac'] = strtolower(str_replace("-", ":", $_POST['spoofmac']));
if (($_POST['ipaddr'] && !is_ipaddr($_POST['ipaddr'])))
- $input_errors[] = "A valid IP address must be specified.";
+ $input_errors[] = gettext("A valid IP address must be specified.");
if (($_POST['subnet'] && !is_numeric($_POST['subnet'])))
- $input_errors[] = "A valid subnet bit count must be specified.";
+ $input_errors[] = gettext("A valid subnet bit count must be specified.");
if (($_POST['alias-address'] && !is_ipaddr($_POST['alias-address'])))
- $input_errors[] = "A valid alias IP address must be specified.";
+ $input_errors[] = gettext("A valid alias IP address must be specified.");
if (($_POST['alias-subnet'] && !is_numeric($_POST['alias-subnet'])))
- $input_errors[] = "A valid alias subnet bit count must be specified.";
+ $input_errors[] = gettext("A valid alias subnet bit count must be specified.");
if ($_POST['gateway'] != "none") {
$match = false;
foreach($a_gateways as $gateway) {
@@ -407,13 +407,13 @@ if ($_POST) {
}
}
if(!$match) {
- $input_errors[] = "A valid gateway must be specified.";
+ $input_errors[] = gettext("A valid gateway must be specified.");
}
}
if (($_POST['provider'] && !is_domain($_POST['provider'])))
- $input_errors[] = "The service name contains invalid characters.";
+ $input_errors[] = gettext("The service name contains invalid characters.");
if (($_POST['pppoe_idletimeout'] != "") && !is_numericint($_POST['pppoe_idletimeout']))
- $input_errors[] = "The idle timeout value must be an integer.";
+ $input_errors[] = gettext("The idle timeout value must be an integer.");
if ($_POST['pppoe_resethour'] <> "" && !is_numericint($_POST['pppoe_resethour']) &&
$_POST['pppoe_resethour'] >= 0 && $_POST['pppoe_resethour'] <=23)
$input_errors[] = gettext("A valid PPPoE reset hour must be specified (0-23).");
@@ -423,21 +423,21 @@ if ($_POST) {
if ($_POST['pppoe_resetdate'] <> "" && !is_numeric(str_replace("/", "", $_POST['pppoe_resetdate'])))
$input_errors[] = gettext("A valid PPPoE reset date must be specified (mm/dd/yyyy).");
if (($_POST['pptp_local'] && !is_ipaddr($_POST['pptp_local'])))
- $input_errors[] = "A valid PPTP local IP address must be specified.";
+ $input_errors[] = gettext("A valid PPTP local IP address must be specified.");
if (($_POST['pptp_subnet'] && !is_numeric($_POST['pptp_subnet'])))
- $input_errors[] = "A valid PPTP subnet bit count must be specified.";
+ $input_errors[] = gettext("A valid PPTP subnet bit count must be specified.");
if (($_POST['pptp_remote'] && !is_ipaddr($_POST['pptp_remote'])))
- $input_errors[] = "A valid PPTP remote IP address must be specified.";
+ $input_errors[] = gettext("A valid PPTP remote IP address must be specified.");
if (($_POST['pptp_idletimeout'] != "") && !is_numericint($_POST['pptp_idletimeout']))
- $input_errors[] = "The idle timeout value must be an integer.";
+ $input_errors[] = gettext("The idle timeout value must be an integer.");
if (($_POST['spoofmac'] && !is_macaddr($_POST['spoofmac'])))
- $input_errors[] = "A valid MAC address must be specified.";
+ $input_errors[] = gettext("A valid MAC address must be specified.");
if ($_POST['mtu'] && ($_POST['mtu'] < 576))
- $input_errors[] = "The MTU must be greater than 576 bytes.";
+ $input_errors[] = gettext("The MTU must be greater than 576 bytes.");
/* Wireless interface? */
if (isset($wancfg['wireless'])) {
$reqdfields = explode(" ", "mode ssid");
- $reqdfieldsn = explode(",", "Mode,SSID");
+ $reqdfieldsn = array(gettext("Mode"),gettext("SSID"));
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
check_wireless_mode();
/* loop through keys and enforce size */
@@ -471,7 +471,7 @@ if ($_POST) {
}
if(strlen($_POST['key' . $i]) == 28)
continue;
- $input_errors[] = "Invalid WEP key size. Sizes should be 40 (64) bit keys or 104 (128) bit.";
+ $input_errors[] = gettext("Invalid WEP key size. Sizes should be 40 (64) bit keys or 104 (128) bit.");
break;
}
}
@@ -479,7 +479,7 @@ if ($_POST) {
if ($_POST['passphrase']) {
$passlen = strlen($_POST['passphrase']);
if ($passlen < 8 || $passlen > 64)
- $input_errors[] = "The length of the passphrase should be between 8 and 63 characters.";
+ $input_errors[] = gettext("The length of the passphrase should be between 8 and 63 characters.");
}
}
if (!$input_errors) {
@@ -525,8 +525,8 @@ if ($_POST) {
}
}
if($skip == false) {
- $gateway_item['gateway'] = "dynamic";
- $gateway_item['descr'] = "Interface {$if} dynamic gateway";
+ $gateway_item['gateway'] = gettext("dynamic");
+ $gateway_item['descr'] = gettext("Interface") . $if . gettext("dynamic gateway");
$gateway_item['name'] = "GW_" . strtoupper($if);
$gateway_item['interface'] = "{$if}";
} else {
@@ -805,7 +805,7 @@ function check_wireless_mode() {
$old_wireless_mode = $wancfg['wireless']['mode'];
$wancfg['wireless']['mode'] = $_POST['mode'];
if (!interface_wireless_clone("{$wlanif}_", $wancfg)) {
- $input_errors[] = "Unable to change mode to {$wlan_modes[$wancfg['wireless']['mode']]}. You may already have the maximum number of wireless clones supported in this mode.";
+ $input_errors[] = sprintf(gettext("Unable to change mode to %s . You may already have the maximum number of wireless clones supported in this mode."), $wlan_modes[$wancfg['wireless']['mode']]);
} else {
mwexec("/sbin/ifconfig {$wlanif}_ destroy");
}
@@ -813,12 +813,12 @@ function check_wireless_mode() {
}
}
-$pgtitle = array("Interfaces", $pconfig['descr']);
+$pgtitle = array(gettext("Interfaces"),sprintf(gettext("'%s'"),$pconfig['descr']));
$statusurl = "status_interfaces.php";
$closehead = false;
include("head.inc");
-$types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" => "PPP", "pppoe" => "PPPoE", "pptp" => "PPTP" /* , "carpdev-dhcp" => "CarpDev"*/);
+$types = array("none" => gettext("None"), "static" => gettext("Static"), "dhcp" => gettext("DHCP"), "ppp" => gettext("PPP"), "pppoe" => gettext("PPPoE"), "pptp" => gettext("PPTP") /* , "carpdev-dhcp" => "CarpDev"*/);
?>
@@ -983,7 +983,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<form action="interfaces.php" method="post" name="iform" id="iform">
<?php if ($input_errors) print_input_errors($input_errors); ?>
<?php if (is_subsystem_dirty('interfaces')): ?><p>
- <?php print_info_box_np(gettext("The {$wancfg['descr']} configuration has been changed.<p>You must apply the changes in order for them to take effect.<p>Don't forget to adjust the DHCP Server range if needed after applying."));?><br />
+ <?php print_info_box_np(printf(gettext("The '%s' configuration has been changed."),$wancfg['descr'])."<p>".gettext("You must apply the changes in order for them to take effect.")."<p>".gettext("Don't forget to adjust the DHCP Server range if needed after applying."));?><br />
<?php endif; ?>
<?php if ($savemsg) print_info_box($savemsg); ?>
<table width="100%" border="0" cellpadding="6" cellspacing="0">
@@ -992,27 +992,27 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<div class="tabcont">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">General configuration</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("General configuration"); ?></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Enable</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Enable"); ?></td>
<td width="78%" class="vtable">
<input name="enable" type="checkbox" value="yes" <?php if ($pconfig['enable'] == true) echo "checked"; ?> onClick="show_allcfg(this);">
- <strong>Enable Interface</strong>
+ <strong><?=gettext("Enable Interface"); ?></strong>
</td>
</tr>
</table>
<div style="display:none;" name="allcfg" id="allcfg">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td width="22%" valign="top" class="vncell">Description</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Description"); ?></td>
<td width="78%" class="vtable">
<input name="descr" type="text" class="formfld unknown" id="descr" size="30" value="<?=htmlspecialchars($pconfig['descr']);?>">
- <br><span class="vexpl">Enter a description (name) for the interface here.</span>
+ <br><span class="vexpl"><?= gettext("Enter a description (name) for the interface here."); ?></span>
</td>
</tr>
<tr>
- <td valign="middle" class="vncell"><strong>Type</strong></td>
+ <td valign="middle" class="vncell"><strong><?=gettext("Type"); ?></strong></td>
<td class="vtable">
<select name="type" onChange="updateType(this.value);" class="formselect" id="type">
<?php
@@ -1028,7 +1028,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</td>
</tr>
<tr>
- <td valign="top" class="vncell">MAC address</td>
+ <td valign="top" class="vncell"><?=gettext("MAC address"); ?></td>
<td class="vtable">
<input name="spoofmac" type="text" class="formfld unknown" id="spoofmac" size="30" value="<?=htmlspecialchars($pconfig['spoofmac']);?>">
<?php
@@ -1037,25 +1037,25 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
$mac = str_replace("\n","",$mac);
if($mac):
?>
- <a OnClick="document.forms[0].spoofmac.value='<?=$mac?>';" href="#">Insert my local MAC address</a>
+ <a OnClick="document.forms[0].spoofmac.value='<?=$mac?>';" href="#"><?=gettext("Insert my local MAC address"); ?></a>
<?php endif; ?>
<br>
- This field can be used to modify (&quot;spoof&quot;) the MAC
- address of the WAN interface<br>
- (may be required with some cable connections)<br>
- Enter a MAC address in the following format: xx:xx:xx:xx:xx:xx
- or leave blank
+ <?=gettext("This field can be used to modify (\"spoof\") the MAC " .
+ "address of the WAN interface"); ?><br>
+ <?=gettext("(may be required with some cable connections)"); ?><br>
+ <?=gettext("Enter a MAC address in the following format: xx:xx:xx:xx:xx:xx " .
+ "or leave blank"); ?>
</td>
</tr>
<tr>
- <td valign="top" class="vncell">MTU</td>
+ <td valign="top" class="vncell"><?=gettext("MTU"); ?></td>
<td class="vtable">
<input name="mtu" type="text" class="formfld unknown" id="mtu" size="8" value="<?=htmlspecialchars($pconfig['mtu']);?>">
<br>
- If you enter a value in this field, then MSS clamping for
- TCP connections to the value entered above minus 40 (TCP/IP
- header size) will be in effect. If you leave this field blank,
- an MTU of 1500 bytes will be assumed.
+ <?=gettext("If you enter a value in this field, then MSS clamping for " .
+ "TCP connections to the value entered above minus 40 (TCP/IP " .
+ "header size) will be in effect. If you leave this field blank, " .
+ "an MTU of 1500 bytes will be assumed"); ?>.
</td>
</tr>
<tr>
@@ -1067,10 +1067,10 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<td colspan="2" style="padding:0px;">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">Static IP configuration</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("Static IP configuration"); ?></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">IP address</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("IP address"); ?></td>
<td width="78%" class="vtable">
<input name="ipaddr" type="text" class="formfld unknown" id="ipaddr" size="20" value="<?=htmlspecialchars($pconfig['ipaddr']);?>">
/
@@ -1088,10 +1088,10 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">Gateway</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Gateway"); ?></td>
<td width="78%" class="vtable">
<select name="gateway" class="formselect" id="gateway">
- <option value="none" selected>None</option>
+ <option value="none" selected><?=gettext("None"); ?></option>
<?php
if(count($a_gateways) > 0) {
foreach ($a_gateways as $gateway) {
@@ -1108,7 +1108,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</select>
<br/>
<div id='addgwbox'>
- If this interface is an Internet connection, select an existing Gateway from the list or <a OnClick="show_add_gateway();" href="#">add a new one</a>.
+ <?=gettext("If this interface is an Internet connection, select an existing Gateway from the list or"); ?> <a OnClick="show_add_gateway();" href="#"><?=gettext("add a new one"); ?></a>.
</div>
<div id='notebox'>
</div>
@@ -1122,7 +1122,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<table bgcolor="#990000" cellpadding="1" cellspacing="1">
<tr><td>&nbsp;</td>
<tr>
- <td colspan="2"><center><b><font color="white">Add new gateway:</font></b></center></td>
+ <td colspan="2"><center><b><font color="white"><?=gettext("Add new gateway"); ?>:</font></b></center></td>
</tr>
<tr><td>&nbsp;</td>
<?php
@@ -1130,16 +1130,16 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
$checked = " CHECKED";
?>
<tr>
- <td width="45%" align="right"><font color="white">Default gateway:</td><td><input type="checkbox" id="defaultgw" name="defaultgw"<?=$checked?>></td>
+ <td width="45%" align="right"><font color="white"><?=gettext("Default gateway"); ?>:</td><td><input type="checkbox" id="defaultgw" name="defaultgw"<?=$checked?>></td>
</tr>
<tr>
- <td align="right"><font color="white">Gateway Name:</td><td><input id="name" name="name" value="<?=$wancfg['descr'] . "GW"?>"></td>
+ <td align="right"><font color="white"><?=gettext("Gateway Name"); ?>:</td><td><input id="name" name="name" value="<?=$wancfg['descr'] . "GW"?>"></td>
</tr>
<tr>
- <td align="right"><font color="white">Gateway IP:</td><td><input id="gatewayip" name="gatewayip"></td>
+ <td align="right"><font color="white"><?=gettext("Gateway IP"); ?>:</td><td><input id="gatewayip" name="gatewayip"></td>
</tr>
<tr>
- <td align="right"><font color="white">Description:</td><td><input id="gatewaydescr" name="gatewaydescr"></td>
+ <td align="right"><font color="white"><?=gettext("Description"); ?>:</td><td><input id="gatewaydescr" name="gatewaydescr"></td>
</tr>
<tr><td>&nbsp;</td>
<tr>
@@ -1147,8 +1147,8 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<center>
<div id='savebuttondiv'>
<input type="hidden" name="addrtype" id="addrtype" value="IPv4" />
- <input id="gwsave" type="Button" value="Save Gateway" onClick='hide_add_gatewaysave();'>
- <input id="gwcancel" type="Button" value="Cancel" onClick='hide_add_gateway();'>
+ <input id="gwsave" type="Button" value="<?=gettext("Save Gateway"); ?>" onClick='hide_add_gatewaysave();'>
+ <input id="gwcancel" type="Button" value="<?=gettext("Cancel"); ?>" onClick='hide_add_gateway();'>
</div>
</center>
</td>
@@ -1169,20 +1169,20 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<td colspan="2" style="padding: 0px;">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">DHCP client configuration</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("DHCP client configuration"); ?></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Hostname</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Hostname"); ?></td>
<td width="78%" class="vtable">
<input name="dhcphostname" type="text" class="formfld unknown" id="dhcphostname" size="40" value="<?=htmlspecialchars($pconfig['dhcphostname']);?>">
<br>
- The value in this field is sent as the DHCP client identifier
- and hostname when requesting a DHCP lease. Some ISPs may require
- this (for client identification).
+ <?=gettext("The value in this field is sent as the DHCP client identifier " .
+ "and hostname when requesting a DHCP lease. Some ISPs may require " .
+ "this (for client identification)"); ?>.
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Alias IP address</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Alias IP address"); ?></td>
<td width="78%" class="vtable">
<input name="alias-address" type="text" class="formfld unknown" id="alias-address" size="20" value="<?=htmlspecialchars($pconfig['alias-address']);?>">
<select name="alias-subnet" class="formselect" id="alias-subnet">
@@ -1196,8 +1196,8 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
}
?>
</select>
- The value in this field is used as a fixed alias IP address by the
- DHCP client.
+ <?=gettext("The value in this field is used as a fixed alias IP address by the " .
+ "DHCP client"); ?>.
</td>
</tr>
</table>
@@ -1207,14 +1207,14 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<td colspan="2" style="padding: 0px;">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">PPP configuration</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("PPP configuration"); ?></td>
</tr>
<tr name="ppp_provider" id="ppp_provider">
- <td width="22%" valign="top" class="vncell"><?= gettext("Service Provider"); ?></td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Service Provider"); ?></td>
<td width="78%" class="vtable">
<table border="0" cellpadding="0" cellspacing="0">
<tr id="trcountry">
- <td><?= gettext("Country"); ?> :&nbsp;&nbsp;</td>
+ <td><?=gettext("Country"); ?> :&nbsp;&nbsp;</td>
<td>
<select class="formselect" name="country" id="country" onChange="providers_list()">
<option></option>
@@ -1222,7 +1222,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</td>
</tr>
<tr id="trprovider" style="display:none">
- <td><?= gettext("Provider"); ?> :&nbsp;&nbsp;</td>
+ <td><?=gettext("Provider"); ?> :&nbsp;&nbsp;</td>
<td>
<select class="formselect" name="provider" id="provider" onChange="providerplan_list()">
<option></option>
@@ -1230,7 +1230,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</td>
</tr>
<tr id="trproviderplan" style="display:none">
- <td><?= gettext("Plan"); ?> :&nbsp;&nbsp;</td>
+ <td><?=gettext("Plan"); ?> :&nbsp;&nbsp;</td>
<td>
<select class="formselect" name="providerplan" id="providerplan" onChange="prefill_provider()">
<option></option>
@@ -1238,35 +1238,35 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</td>
</tr>
</table>
- <br/><span class="vexpl"><?= gettext("Select to fill in data for your service provider."); ?></span>
+ <br/><span class="vexpl"><?=gettext("Select to fill in data for your service provider."); ?></span>
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell"><?= gettext("Username"); ?></td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Username"); ?></td>
<td width="78%" class="vtable">
<input name="username" type="text" class="formfld user" id="username" size="20" value="<?=htmlspecialchars($pconfig['username']);?>">
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell"><?= gettext("Password"); ?></td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Password"); ?></td>
<td width="78%" class="vtable">
<input name="password" type="password" class="formfld pwd" id="password" size="20" value="<?=htmlspecialchars($pconfig['password']);?>">
</td>
</tr>
<tr name="phone_num" id="phone_num">
- <td width="22%" valign="top" class="vncellreq"><?= gettext("Phone Number"); ?></td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Phone Number"); ?></td>
<td width="78%" class="vtable">
<input name="phone" type="text" class="formfld unknown" id="phone" size="12" value="<?=htmlspecialchars($pconfig['phone']);?>">
</td>
</tr>
<tr name="apn_" id="apn_">
- <td width="22%" valign="top" class="vncell"><?= gettext("Access Point Name (APN)"); ?></td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Access Point Name (APN)"); ?></td>
<td width="78%" class="vtable">
<input name="apn" type="text" class="formfld unknown" id="apn" size="40" value="<?=htmlspecialchars($pconfig['apn']);?>">
</td>
</tr>
<tr name="interface" id="interface" >
- <td width="22%" valign="top" class="vncellreq"><?= gettext("Modem Port"); ?></td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Modem Port"); ?></td>
<td width="78%" class="vtable">
<select name="port" id="port" class="formselect">
<?php
@@ -1284,16 +1284,16 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</select>
</td>
</tr>
- <td width="22%" valign="top" class="vncell"><?= gettext("Advanced PPP"); ?></td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Advanced PPP"); ?></td>
<?php if (isset($pconfig['pppid'])): ?>
<td width="78%" class="vtable">
- <a href="/interfaces_ppps_edit.php?id=<?=htmlspecialchars($pconfig['pppid']);?>" class="navlnk">Click here</a>
- to edit PPP configuration.
+ <a href="/interfaces_ppps_edit.php?id=<?=htmlspecialchars($pconfig['pppid']);?>" class="navlnk"><?=gettext("Click here "); ?></a>
+ <?=gettext("to edit PPP configuration"); ?>.
</td>
<? else: ?>
<td width="78%" class="vtable">
- <a href="/interfaces_ppps_edit.php" class="navlnk">Click here</a>
- to create a PPP configuration.
+ <a href="/interfaces_ppps_edit.php" class="navlnk"><?=gettext("Click here"); ?></a>
+ <?=gettext("to create a PPP configuration"); ?>.
</td>
<? endif; ?>
</tr>
@@ -1304,38 +1304,38 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<td colspan="2" style="padding:0px;">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">PPPoE configuration</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("PPPoE configuration"); ?></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">Username</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Username"); ?></td>
<td width="78%" class="vtable">
<input name="pppoe_username" type="text" class="formfld user" id="pppoe_username" size="20" value="<?=htmlspecialchars($pconfig['pppoe_username']);?>">
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">Password</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Password"); ?></td>
<td width="78%" class="vtable">
<input name="pppoe_password" type="password" class="formfld pwd" id="pppoe_password" size="20" value="<?=htmlspecialchars($pconfig['pppoe_password']);?>">
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Service name</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Service name"); ?></td>
<td width="78%" class="vtable"><input name="provider" type="text" class="formfld unknown" id="provider" size="20" value="<?=htmlspecialchars($pconfig['provider']);?>">
- <br> <span class="vexpl">Hint: this field can usually be left empty</span>
+ <br> <span class="vexpl"><?=gettext("Hint: this field can usually be left empty"); ?></span>
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Dial on demand</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Dial on demand"); ?></td>
<td width="78%" class="vtable">
<input name="pppoe_dialondemand" type="checkbox" id="pppoe_dialondemand" value="enable" <?php if ($pconfig['pppoe_dialondemand']) echo "checked"; ?>>
- <strong>Enable Dial-On-Demand mode</strong><br>
- This option causes the interface to operate in dial-on-demand mode, allowing you to have a <i>virtual full time</i> connection. The interface is configured, but the actual connection of the link is delayed until qualifying outgoing traffic is detected.
+ <strong><?=gettext("Enable Dial-On-Demand mode"); ?></strong><br>
+ <?=gettext("This option causes the interface to operate in dial-on-demand mode, allowing you to have a "); ?><i><?=gettext("virtual full time"); ?></i> <?=gettext("connection. The interface is configured, but the actual connection of the link is delayed until qualifying outgoing traffic is detected"); ?>.
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Idle timeout</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Idle timeout"); ?></td>
<td width="78%" class="vtable">
- <input name="pppoe_idletimeout" type="text" class="formfld unknown" id="pppoe_idletimeout" size="8" value="<?=htmlspecialchars($pconfig['pppoe_idletimeout']);?>"> seconds<br>If no qualifying outgoing packets are transmitted for the specified number of seconds, the connection is brought down. An idle timeout of zero disables this feature.
+ <input name="pppoe_idletimeout" type="text" class="formfld unknown" id="pppoe_idletimeout" size="8" value="<?=htmlspecialchars($pconfig['pppoe_idletimeout']);?>"> <?=gettext("seconds"); ?><br><?=gettext("If no qualifying outgoing packets are transmitted for the specified number of seconds, the connection is brought down. An idle timeout of zero disables this feature"); ?>.
</td>
</tr>
<tr>
@@ -1346,10 +1346,10 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<td align="left" valign="top">
<p style="margin: 4px; padding: 4px 0 4px 0; width: 94%;">
<select valign="top" id="reset_type" name="pppoe-reset-type" class="formselect" onChange="show_reset_settings(this.value);">
- <option value = ""><?= gettext("Disabled"); ?></option>
- <option value="custom" <?php if ($pconfig['pppoe-reset-type'] == "custom") echo "selected"; ?>><?= gettext("Custom"); ?></option>
- <option value="preset" <?php if ($pconfig['pppoe-reset-type'] == "preset") echo "selected"; ?>><?= gettext("Pre-Set"); ?></option>
- </select> <?= gettext("Select a reset timing type"); ?>
+ <option value = ""><?=gettext("Disabled"); ?></option>
+ <option value="custom" <?php if ($pconfig['pppoe-reset-type'] == "custom") echo "selected"; ?>><?=gettext("Custom"); ?></option>
+ <option value="preset" <?php if ($pconfig['pppoe-reset-type'] == "preset") echo "selected"; ?>><?=gettext("Pre-Set"); ?></option>
+ </select> <?=gettext("Select a reset timing type"); ?>
</p>
<?php if ($pconfig['pppoe_pr_custom']): ?>
<p style="margin: 2px; padding: 4px; width: 94%;" id="pppoecustomwrap">
@@ -1357,14 +1357,14 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<p style="margin: 2px; padding: 4px; width: 94%; display: none;" id="pppoecustomwrap">
<?php endif; ?>
<input type="text" name="pppoe_resethour" class="fd_incremental_inp_range_0_23 fd_increment_1 fd_classname_dec_buttonDec fd_classname_inc_buttonInc" maxlength="2" id="pppoe_resethour" value="<?= $pconfig['pppoe_resethour']; ?>" size="3" />
- <?= gettext("hour (0-23)"); ?><br />
+ <?=gettext("hour (0-23)"); ?><br />
<input type="text" name="pppoe_resetminute" class="fd_incremental_inp_range_0_59 fd_increment_1 fd_classname_dec_buttonDec fd_classname_inc_buttonInc" maxlength="2" id="pppoe_resetminute" value="<?= $pconfig['pppoe_resetminute']; ?>" size="3" />
- <?= gettext("minute (0-59)"); ?><br />
+ <?=gettext("minute (0-59)"); ?><br />
<input name="pppoe_resetdate" type="text" class="w8em format-m-d-y highlight-days-67" id="pppoe_resetdate" maxlength="10" size="10" value="<?=htmlspecialchars($pconfig['pppoe_resetdate']);?>" />
- <?= gettext("reset at a specific date (mm/dd/yyyy)"); ?>
+ <?=gettext("reset at a specific date (mm/dd/yyyy)"); ?>
<br />&nbsp;<br />
- <span class="red"><strong>Note: </strong></span>
- <?= gettext("If you leave the date field empty, the reset will be executed each day at the time you did specify using the minutes and hour field."); ?>
+ <span class="red"><strong><?=gettext("Note"); ?>: </strong></span>
+ <?=gettext("If you leave the date field empty, the reset will be executed each day at the time you did specify using the minutes and hour field."); ?>
</p>
<?php if ($pconfig['pppoe_pr_preset']): ?>
<p style="margin: 2px; padding: 4px; width: 94%;" id="pppoepresetwrap">
@@ -1372,16 +1372,16 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<p style="margin: 2px; padding: 4px; width: 94%; display: none;" id="pppoepresetwrap">
<?php endif; ?>
<input name="pppoe_pr_preset_val" type="radio" id="pppoe_monthly" value="monthly" <?php if ($pconfig['pppoe_monthly']) echo "checked=\"checked\""; ?> />
- <?= gettext("reset at each month ('0 0 1 * *')"); ?>
+ <?=gettext("reset at each month ('0 0 1 * *')"); ?>
<br />
<input name="pppoe_pr_preset_val" type="radio" id="pppoe_weekly" value="weekly" <?php if ($pconfig['pppoe_weekly']) echo "checked=\"checked\""; ?> />
- <?= gettext("reset at each week ('0 0 * * 0')"); ?>
+ <?=gettext("reset at each week ('0 0 * * 0')"); ?>
<br />
<input name="pppoe_pr_preset_val" type="radio" id="pppoe_daily" value="daily" <?php if ($pconfig['pppoe_daily']) echo "checked=\"checked\""; ?> />
- <?= gettext("reset at each day ('0 0 * * *')"); ?>
+ <?=gettext("reset at each day ('0 0 * * *')"); ?>
<br />
<input name="pppoe_pr_preset_val" type="radio" id="pppoe_hourly" value="hourly" <?php if ($pconfig['pppoe_hourly']) echo "checked=\"checked\""; ?> />
- <?= gettext("reset at each hour ('0 * * * *')"); ?>
+ <?=gettext("reset at each hour ('0 * * * *')"); ?>
</p>
</td>
</tr>
@@ -1390,16 +1390,16 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Advanced and MLPPP</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Advanced and MLPPP"); ?></td>
<?php if (isset($pconfig['pppid'])): ?>
<td width="78%" class="vtable">
- <a href="/interfaces_ppps_edit.php?id=<?=htmlspecialchars($pconfig['pppid']);?>" class="navlnk">Click here</a>
- for additional PPPoE configuration options. Save first if you made changes.
+ <a href="/interfaces_ppps_edit.php?id=<?=htmlspecialchars($pconfig['pppid']);?>" class="navlnk"><?=gettext("Click here"); ?> </a>
+ <?=gettext("for additional PPPoE configuration options. Save first if you made changes"); ?>.
</td>
<? else: ?>
<td width="78%" class="vtable">
- <a href="/interfaces_ppps_edit.php" class="navlnk">Click here</a>
- for advanced PPPoE configuration options and MLPPP configuration.
+ <a href="/interfaces_ppps_edit.php" class="navlnk"><?=gettext("Click here"); ?> </a>
+ <?=gettext("for advanced PPPoE configuration options and MLPPP configuration"); ?>.
</td>
<? endif; ?>
</tr>
@@ -1410,22 +1410,22 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<td colspan="2" style="padding:0px;">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">PPTP configuration</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("PPTP configuration"); ?></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">Username</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Username"); ?></td>
<td width="78%" class="vtable">
<input name="pptp_username" type="text" class="formfld user" id="pptp_username" size="20" value="<?=htmlspecialchars($pconfig['pptp_username']);?>">
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">Password</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Password"); ?></td>
<td width="78%" class="vtable">
<input name="pptp_password" type="password" class="formfld pwd" id="pptp_password" size="20" value="<?=htmlspecialchars($pconfig['pptp_password']);?>">
</td>
</tr>
<tr>
- <td width="22%" width="100" valign="top" class="vncellreq">Local IP address</td>
+ <td width="22%" width="100" valign="top" class="vncellreq"><?=gettext("Local IP address"); ?></td>
<td width="78%" class="vtable">
<input name="pptp_local" type="text" class="formfld unknown" id="pptp_local" size="20" value="<?=htmlspecialchars($pconfig['pptp_local'][0]);?>">
/
@@ -1438,36 +1438,36 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</td>
</tr>
<tr>
- <td width="22%" width="100" valign="top" class="vncellreq">Remote IP address</td>
+ <td width="22%" width="100" valign="top" class="vncellreq"><?=gettext("Remote IP address"); ?></td>
<td width="78%" class="vtable">
<input name="pptp_remote" type="text" class="formfld unknown" id="pptp_remote" size="20" value="<?=htmlspecialchars($pconfig['pptp_remote'][0]);?>">
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Dial on demand</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Dial on demand"); ?></td>
<td width="78%" class="vtable">
<input name="pptp_dialondemand" type="checkbox" id="pptp_dialondemand" value="enable" <?php if ($pconfig['pptp_dialondemand']) echo "checked"; ?>>
- <strong>Enable Dial-On-Demand mode</strong><br>
- This option causes the interface to operate in dial-on-demand mode, allowing you to have a <i>virtual full time</i> connection. The interface is configured, but the actual connection of the link is delayed until qualifying outgoing traffic is detected.
+ <strong><?=gettext("Enable Dial-On-Demand mode"); ?></strong><br>
+ <?=gettext("This option causes the interface to operate in dial-on-demand mode, allowing you to have a"); ?> <i><?=gettext("virtual full time"); ?></i> <?=gettext("connection. The interface is configured, but the actual connection of the link is delayed until qualifying outgoing traffic is detected"); ?>.
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Idle timeout</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Idle timeout"); ?></td>
<td width="78%" class="vtable">
- <input name="pptp_idletimeout" type="text" class="formfld unknown" id="pptp_idletimeout" size="8" value="<?=htmlspecialchars($pconfig['pptp_idletimeout']);?>"> seconds<br>If no qualifying outgoing packets are transmitted for the specified number of seconds, the connection is brought down. An idle timeout of zero disables this feature.
+ <input name="pptp_idletimeout" type="text" class="formfld unknown" id="pptp_idletimeout" size="8" value="<?=htmlspecialchars($pconfig['pptp_idletimeout']);?>"> <?=gettext("seconds"); ?><br><?=gettext("If no qualifying outgoing packets are transmitted for the specified number of seconds, the connection is brought down. An idle timeout of zero disables this feature"); ?>.
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Advanced</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Advanced"); ?></td>
<?php if (isset($pconfig['pppid'])): ?>
<td width="78%" class="vtable">
- <a href="/interfaces_ppps_edit.php?id=<?=htmlspecialchars($pconfig['pppid']);?>" class="navlnk">Click here</a>
- for additional PPTP and L2TP configuration options. Save first if you made changes.
+ <a href="/interfaces_ppps_edit.php?id=<?=htmlspecialchars($pconfig['pppid']);?>" class="navlnk"><?=gettext("Click here");?></a>
+ <?=gettext("for additional PPTP and L2TP configuration options. Save first if you made changes");?>.
</td>
<? else: ?>
<td width="78%" class="vtable">
- <a href="/interfaces_ppps_edit.php" class="navlnk">Click here</a>
- for advanced PPTP and L2TP configuration options.
+ <a href="/interfaces_ppps_edit.php" class="navlnk"><?=gettext("Click here");?></a>
+ <?=gettext("for advanced PPTP and L2TP configuration options");?>.
</td>
<? endif; ?>
</tr>
@@ -1482,17 +1482,17 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<td colspan="2" valign="top" height="16"></td>
</tr>
<tr>
- <td colspan="2" valign="top" class="listtopic">Common wireless configuration - Settings apply to all wireless networks on <?=$wlanbaseif;?>.</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("Common wireless configuration - Settings apply to all wireless networks on"); ?> <?=$wlanbaseif;?>.</td>
</tr>
<tr>
- <td valign="top" class="vncell">Persist common settings</td>
+ <td valign="top" class="vncell"><?=gettext("Persist common settings");?></td>
<td class="vtable">
<input name="persistcommonwireless" type="checkbox" value="yes" class="formfld" id="persistcommonwireless" <? if ($pconfig['persistcommonwireless']) echo "checked";?>>
- <br/>Enabling this preserves the common wireless configuration through interface deletions and reassignments.
+ <br/><?=gettext("Enabling this preserves the common wireless configuration through interface deletions and reassignments");?>.
</td>
</tr>
<tr>
- <td valign="top" class="vncellreq">Standard</td>
+ <td valign="top" class="vncellreq"><?=gettext("Standard"); ?></td>
<td class="vtable">
<select name="standard" class="formselect" id="standard">
<?php
@@ -1508,15 +1508,15 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</tr>
<?php if (isset($wl_modes['11g'])): ?>
<tr>
- <td valign="top" class="vncellreq">802.11g OFDM Protection Mode</td>
+ <td valign="top" class="vncellreq">802.11g OFDM <?=gettext("Protection Mode"); ?></td>
<td class="vtable">
<select name="protmode" class="formselect" id="protmode">
- <option <? if ($pconfig['protmode'] == 'off') echo "selected";?> value="off">Protection mode off</option>
- <option <? if ($pconfig['protmode'] == 'cts') echo "selected";?> value="cts">Protection mode CTS to self</option>
- <option <? if ($pconfig['protmode'] == 'rtscts') echo "selected";?> value="rtscts">Protection mode RTS and CTS</option>
+ <option <? if ($pconfig['protmode'] == 'off') echo "selected";?> value="off"><?=gettext("Protection mode off"); ?></option>
+ <option <? if ($pconfig['protmode'] == 'cts') echo "selected";?> value="cts"><?=gettext("Protection mode CTS to self"); ?></option>
+ <option <? if ($pconfig['protmode'] == 'rtscts') echo "selected";?> value="rtscts"><?=gettext("Protection mode RTS and CTS"); ?></option>
</select>
<br/>
- For IEEE 802.11g, use the specified technique for protecting OFDM frames in a mixed 11b/11g network.
+ <?=gettext("For IEEE 802.11g, use the specified technique for protecting OFDM frames in a mixed 11b/11g network"); ?>.
<br/>
</td>
</tr>
@@ -1524,7 +1524,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<input name="protmode" type="hidden" id="protmode" value="off">
<?php endif; ?>
<tr>
- <td valign="top" class="vncellreq">Transmit power</td>
+ <td valign="top" class="vncellreq"><?=gettext("Transmit power"); ?></td>
<td class="vtable">
<select name="txpower" class="formselect" id="txpower">
<?
@@ -1537,14 +1537,14 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
}
?>
</select><br/>
- Note: Typically only a few discreet power settings are available and the driver will use the setting closest to the specified value. Not all adaptors support changing the transmit power setting.
+ <?=gettext("Note: Typically only a few discreet power settings are available and the driver will use the setting closest to the specified value. Not all adaptors support changing the transmit power setting"); ?>.
</td>
</tr>
<tr>
- <td valign="top" class="vncellreq">Channel</td>
+ <td valign="top" class="vncellreq"><?=gettext("Channel"); ?></td>
<td class="vtable">
<select name="channel" class="formselect" id="channel">
- <option <? if ($pconfig['channel'] == 0) echo "selected"; ?> value="0">Auto</option>
+ <option <? if ($pconfig['channel'] == 0) echo "selected"; ?> value="0"><?=gettext("Auto"); ?></option>
<?php
foreach($wl_modes as $wl_standard => $wl_channels) {
if($wl_standard == "11g") { $wl_standard = "11b/g"; }
@@ -1564,26 +1564,26 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
?>
</select>
<br/>
- Legend: wireless standards - channel # (frequency @ max TX power / TX power allowed in reg. domain)
+ <?=gettext("Legend: wireless standards - channel # (frequency @ max TX power / TX power allowed in reg. domain)"); ?>
<br/>
- Note: Not all channels may be supported by your card. Auto may override the wireless standard selected above.
+ <?=gettext("Note: Not all channels may be supported by your card. Auto may override the wireless standard selected above"); ?>.
</td>
</tr>
<tr>
- <td valign="top" class="vncell">Distance setting</td>
+ <td valign="top" class="vncell"><?=gettext("Distance setting"); ?></td>
<td class="vtable">
<input name="distance" type="text" class="formfld unknown" id="distance" size="5" value="<?=htmlspecialchars($pconfig['distance']);?>">
<br/>
- Note: This field can be used to tune ACK/CTS timers to fit the distance between AP and Client<br/>
- (measured in Meters and works only for Atheros based cards !)
+ <?=gettext("Note: This field can be used to tune ACK/CTS timers to fit the distance between AP and Client"); ?><br/>
+ <?=gettext("(measured in Meters and works only for Atheros based cards !)"); ?>
</td>
</tr>
<tr>
- <td valign="top" class="vncell">Regulatory settings</td>
+ <td valign="top" class="vncell"><?=gettext("Regulatory settings"); ?></td>
<td class="vtable">
- Regulatory domain<br/>
+ <?=gettext("Regulatory domain"); ?><br/>
<select name="regdomain" class="formselect" id="regdomain">
- <option <? if (empty($pconfig['regdomain'])) echo "selected"; ?> value="">Default</option>
+ <option <? if (empty($pconfig['regdomain'])) echo "selected"; ?> value=""><?=gettext("Default"); ?></option>
<?php
foreach($wl_regdomains as $wl_regdomain_key => $wl_regdomain) {
echo "<option ";
@@ -1595,11 +1595,11 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
?>
</select>
<br/>
- Note: Some cards have a default that is not recognized and require changing the regulatory domain to one in this list for the changes to other regulatory settings to work.
+ <?=gettext("Note: Some cards have a default that is not recognized and require changing the regulatory domain to one in this list for the changes to other regulatory settings to work"); ?>.
<br/><br/>
- Country (listed with country code and regulatory domain)<br/>
+ <?=gettext("Country (listed with country code and regulatory domain)"); ?><br/>
<select name="regcountry" class="formselect" id="regcountry">
- <option <? if (empty($pconfig['regcountry'])) echo "selected"; ?> value="">Default</option>
+ <option <? if (empty($pconfig['regcountry'])) echo "selected"; ?> value=""><?=gettext("Default"); ?></option>
<?php
foreach($wl_countries as $wl_country_key => $wl_country) {
echo "<option ";
@@ -1611,107 +1611,107 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
?>
</select>
<br/>
- Note: Any country setting other than "Default" will override the regulatory domain setting.
+ <?=gettext("Note: Any country setting other than \"Default\" will override the regulatory domain setting"); ?>.
<br/><br/>
- Location<br/>
+ <?=gettext("Location"); ?><br/>
<select name="reglocation" class="formselect" id="reglocation">
- <option <? if (empty($pconfig['reglocation'])) echo "selected"; ?> value="">Default</option>
- <option <? if ($pconfig['reglocation'] == 'indoor') echo "selected"; ?> value="indoor">Indoor</option>
- <option <? if ($pconfig['reglocation'] == 'outdoor') echo "selected"; ?> value="outdoor">Outdoor</option>
- <option <? if ($pconfig['reglocation'] == 'anywhere') echo "selected"; ?> value="anywhere">Anywhere</option>
+ <option <? if (empty($pconfig['reglocation'])) echo "selected"; ?> value=""><?=gettext("Default"); ?></option>
+ <option <? if ($pconfig['reglocation'] == 'indoor') echo "selected"; ?> value="indoor"><?=gettext("Indoor"); ?></option>
+ <option <? if ($pconfig['reglocation'] == 'outdoor') echo "selected"; ?> value="outdoor"><?=gettext("Outdoor"); ?></option>
+ <option <? if ($pconfig['reglocation'] == 'anywhere') echo "selected"; ?> value="anywhere"><?=gettext("Anywhere"); ?></option>
</select>
<br/><br/>
- These settings may affect which channels are available and the maximum transmit power allowed on those channels. Using the correct settings to comply with local regulatory requirements is recommended.
+ <?=gettext("These settings may affect which channels are available and the maximum transmit power allowed on those channels. Using the correct settings to comply with local regulatory requirements is recommended"); ?>.
<br/>
- Note: All wireless networks on this interface will be temporarily brought down when changing regulatory settings. Some of the regulatory domains or country codes may not be allowed by some cards. These settings may not be able to add additional channels that are not already supported.
+ <?=gettext("Note: All wireless networks on this interface will be temporarily brought down when changing regulatory settings. Some of the regulatory domains or country codes may not be allowed by some cards. These settings may not be able to add additional channels that are not already supported"); ?>.
</td>
</tr>
<tr>
<td colspan="2" valign="top" height="16"></td>
</tr>
<tr>
- <td colspan="2" valign="top" class="listtopic">Network-specific wireless configuration</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("Network-specific wireless configuration");?></td>
</tr>
<tr>
- <td valign="top" class="vncellreq">Mode</td>
+ <td valign="top" class="vncellreq"><?=gettext("Mode"); ?></td>
<td class="vtable">
<select name="mode" class="formselect" id="mode">
- <option <? if ($pconfig['mode'] == 'bss') echo "selected";?> value="bss">Infrastructure (BSS)</option>
- <option <? if ($pconfig['mode'] == 'adhoc') echo "selected";?> value="adhoc">Ad-hoc (IBSS)</option>
- <option <? if ($pconfig['mode'] == 'hostap') echo "selected";?> value="hostap">Access Point</option>
+ <option <? if ($pconfig['mode'] == 'bss') echo "selected";?> value="bss"><?=gettext("Infrastructure (BSS)"); ?></option>
+ <option <? if ($pconfig['mode'] == 'adhoc') echo "selected";?> value="adhoc"><?=gettext("Ad-hoc (IBSS)"); ?></option>
+ <option <? if ($pconfig['mode'] == 'hostap') echo "selected";?> value="hostap"><?=gettext("Access Point"); ?></option>
</select>
</td>
</tr>
<tr>
- <td valign="top" class="vncellreq">SSID</td>
+ <td valign="top" class="vncellreq"><?=gettext("SSID"); ?></td>
<td class="vtable">
<input name="ssid" type="text" class="formfld unknown" id="ssid" size="20" value="<?=htmlspecialchars($pconfig['ssid']); ?>">
</td>
</tr>
<?php if (isset($wl_modes['11ng']) || isset($wl_modes['11na'])): ?>
<tr>
- <td valign="top" class="vncell">Minimum wireless standard</td>
+ <td valign="top" class="vncell"><?=gettext("Minimum wireless standard"); ?></td>
<td class="vtable">
<select name="puremode" class="formselect" id="puremode">
- <option <? if ($pconfig['puremode'] == 'any') echo "selected";?> value="any">Any</option>
+ <option <? if ($pconfig['puremode'] == 'any') echo "selected";?> value="any"><?=gettext("Any"); ?></option>
<?php if (isset($wl_modes['11g'])): ?>
<option <? if ($pconfig['puremode'] == '11g') echo "selected";?> value="11g">802.11g</option>
<?php endif; ?>
<option <? if ($pconfig['puremode'] == '11n') echo "selected";?> value="11n">802.11n</option>
</select>
<br/>
- When operating as an access point, allow only stations capable of the selected wireless standard to associate (stations not capable are not permitted to associate).
+ <?=gettext("When operating as an access point, allow only stations capable of the selected wireless standard to associate (stations not capable are not permitted to associate)"); ?>.
</td>
</tr>
<?php elseif (isset($wl_modes['11g'])): ?>
<tr>
- <td valign="top" class="vncell">802.11g only</td>
+ <td valign="top" class="vncell">802.11g <?=gettext("only"); ?></td>
<td class="vtable">
<input name="puremode" type="checkbox" value="11g" class="formfld" id="puremode" <? if ($pconfig['puremode'] == '11g') echo "checked";?>>
- <br/>When operating as an access point in 802.11g mode, allow only 11g-capable stations to associate (11b-only stations are not permitted to associate).
+ <br/><?=gettext("When operating as an access point in 802.11g mode, allow only 11g-capable stations to associate (11b-only stations are not permitted to associate)"); ?>.
</td>
</tr>
<?php endif; ?>
<tr>
- <td valign="top" class="vncell">Allow intra-BSS communication</td>
+ <td valign="top" class="vncell"><?=gettext("Allow intra-BSS communication"); ?></td>
<td class="vtable">
<input name="apbridge_enable" type="checkbox" value="yes" class="formfld" id="apbridge_enable" <? if ($pconfig['apbridge_enable']) echo "checked";?>>
<br/>
- When operating as an access point, enable this if you want to pass packets between wireless clients directly.
+ <?=gettext("When operating as an access point, enable this if you want to pass packets between wireless clients directly"); ?>.
<br/>
- Disabling the internal bridging is useful when traffic is to be processed with packet filtering.
+ <?=gettext("Disabling the internal bridging is useful when traffic is to be processed with packet filtering"); ?>.
</td>
</tr>
<tr>
- <td valign="top" class="vncell">Enable WME</td>
+ <td valign="top" class="vncell"><?=gettext("Enable WME"); ?></td>
<td class="vtable">
<input name="wme_enable" type="checkbox" class="formfld" id="wme_enable" value="yes" <? if ($pconfig['wme_enable']) echo "checked";?>>
- <br/>Setting this option will force the card to use WME (wireless QoS).
+ <br/><?=gettext("Setting this option will force the card to use WME (wireless QoS)"); ?>.
</td>
</tr>
<tr>
- <td valign="top" class="vncell">Enable Hide SSID</td>
+ <td valign="top" class="vncell"><?=gettext("Enable Hide SSID"); ?></td>
<td class="vtable">
<input name="hidessid_enable" type="checkbox" class="formfld" id="hidessid_enable" value="yes" <? if ($pconfig['hidessid_enable']) echo "checked";?>>
<br/>
- Setting this option will force the card to NOT broadcast its SSID
+ <?=gettext("Setting this option will force the card to NOT broadcast its SSID"); ?>
<br/>
- (this might create problems for some clients).
+ <?=gettext("(this might create problems for some clients)"); ?>.
</td>
</tr>
<tr>
- <td valign="top" class="vncell">WEP</td>
+ <td valign="top" class="vncell"><?=gettext("WEP"); ?></td>
<td class="vtable">
<input name="wep_enable" type="checkbox" id="wep_enable" value="yes" <? if ($pconfig['wep_enable']) echo "checked"; ?>>
- <strong>Enable WEP</strong>
+ <strong><?=gettext("Enable WEP"); ?></strong>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td>&nbsp;</td>
<td>&nbsp;</td>
- <td>&nbsp;TX key&nbsp;</td>
+ <td>&nbsp;<?=gettext("TX key"); ?>&nbsp;</td>
</tr>
<tr>
- <td>Key 1:&nbsp;&nbsp;</td>
+ <td><?=gettext("Key"); ?> 1:&nbsp;&nbsp;</td>
<td>
<input name="key1" type="text" class="formfld unknown" id="key1" size="30" value="<?=htmlspecialchars($pconfig['key1']);?>">
</td>
@@ -1720,7 +1720,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</td>
</tr>
<tr>
- <td>Key 2:&nbsp;&nbsp;</td>
+ <td><?=gettext("Key"); ?> 2:&nbsp;&nbsp;</td>
<td>
<input name="key2" type="text" class="formfld unknown" id="key2" size="30" value="<?=htmlspecialchars($pconfig['key2']);?>">
</td>
@@ -1729,7 +1729,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</td>
</tr>
<tr>
- <td>Key 3:&nbsp;&nbsp;</td>
+ <td><?=gettext("Key"); ?> 3:&nbsp;&nbsp;</td>
<td>
<input name="key3" type="text" class="formfld unknown" id="key3" size="30" value="<?=htmlspecialchars($pconfig['key3']);?>">
</td>
@@ -1738,7 +1738,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</td>
</tr>
<tr>
- <td>Key 4:&nbsp;&nbsp;</td>
+ <td><?=gettext("Key"); ?> 4:&nbsp;&nbsp;</td>
<td>
<input name="key4" type="text" class="formfld unknown" id="key4" size="30" value="<?=htmlspecialchars($pconfig['key4']);?>">
</td>
@@ -1748,117 +1748,117 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</tr>
</table>
<br/>
- 40 (64) bit keys may be entered as 5 ASCII characters or 10 hex digits preceded by '0x'.<br/>
- 104 (128) bit keys may be entered as 13 ASCII characters or 26 hex digits preceded by '0x'.
+ <?=gettext("40 (64) bit keys may be entered as 5 ASCII characters or 10 hex digits preceded by '0x'"); ?>.<br/>
+ <?=gettext("104 (128) bit keys may be entered as 13 ASCII characters or 26 hex digits preceded by '0x'"); ?>.
</td>
</tr>
<tr>
- <td valign="top" class="vncell">WPA</td>
+ <td valign="top" class="vncell"><?=gettext("WPA"); ?></td>
<td class="vtable">
<input name="wpa_enable" type="checkbox" class="formfld" id="wpa_enable" value="yes" <? if ($pconfig['wpa_enable']) echo "checked"; ?>>
- <strong>Enable WPA</strong>
+ <strong><?=gettext("Enable WPA"); ?></strong>
<br/><br/>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td>&nbsp;</td>
- <td>&nbsp;WPA Pre Shared Key&nbsp;</td>
+ <td>&nbsp;<?=gettext("WPA Pre Shared Key"); ?>&nbsp;</td>
</tr>
<tr>
- <td>PSK:&nbsp;&nbsp;</td>
+ <td><?=gettext("PSK"); ?>:&nbsp;&nbsp;</td>
<td>
<input name="passphrase" type="text" class="formfld unknown" id="passphrase" size="66" value="<?=htmlspecialchars($pconfig['passphrase']);?>">
</td>
</tr>
</table>
- <br/>Passphrase must be from 8 to 63 characters.
+ <br/><?=gettext("Passphrase must be from 8 to 63 characters"); ?>.
</td>
</tr>
<tr>
- <td valign="top" class="vncell">WPA Mode</td>
+ <td valign="top" class="vncell"><?=gettext("WPA Mode"); ?></td>
<td class="vtable">
<select name="wpa_mode" class="formselect" id="wpa_mode">
- <option <? if ($pconfig['wpa_mode'] == '1') echo "selected";?> value="1">WPA</option>
- <option <? if ($pconfig['wpa_mode'] == '2') echo "selected";?> value="2">WPA2</option>
- <option <? if ($pconfig['wpa_mode'] == '3') echo "selected";?> value="3">Both</option>
+ <option <? if ($pconfig['wpa_mode'] == '1') echo "selected";?> value="1"><?=gettext("WPA"); ?></option>
+ <option <? if ($pconfig['wpa_mode'] == '2') echo "selected";?> value="2"><?=gettext("WPA2"); ?></option>
+ <option <? if ($pconfig['wpa_mode'] == '3') echo "selected";?> value="3"><?=gettext("Both"); ?></option>
</select>
</td>
</tr>
<tr>
- <td valign="top" class="vncell">WPA Key Management Mode</td>
+ <td valign="top" class="vncell"><?=gettext("WPA Key Management Mode"); ?></td>
<td class="vtable">
<select name="wpa_key_mgmt" class="formselect" id="wpa_key_mgmt">
- <option <? if ($pconfig['wpa_key_mgmt'] == 'WPA-PSK') echo "selected";?> value="WPA-PSK">Pre Shared Key</option>
- <option <? if ($pconfig['wpa_key_mgmt'] == 'WPA-EAP') echo "selected";?> value="WPA-EAP">Extensible Authentication Protocol</option>
- <option <? if ($pconfig['wpa_key_mgmt'] == 'WPA-PSK WPA-EAP') echo "selected";?> value="WPA-PSK WPA-EAP">Both</option>
+ <option <? if ($pconfig['wpa_key_mgmt'] == 'WPA-PSK') echo "selected";?> value="WPA-PSK"><?=gettext("Pre Shared Key"); ?></option>
+ <option <? if ($pconfig['wpa_key_mgmt'] == 'WPA-EAP') echo "selected";?> value="WPA-EAP"><?=gettext("Extensible Authentication Protocol"); ?></option>
+ <option <? if ($pconfig['wpa_key_mgmt'] == 'WPA-PSK WPA-EAP') echo "selected";?> value="WPA-PSK WPA-EAP"><?=gettext("Both"); ?></option>
</select>
</td>
</tr>
<tr>
- <td valign="top" class="vncell">Authentication</td>
+ <td valign="top" class="vncell"><?=gettext("Authentication"); ?></td>
<td class="vtable">
<select name="auth_algs" class="formselect" id="auth_algs">
- <option <? if ($pconfig['auth_algs'] == '1') echo "selected";?> value="1">Open System Authentication</option>
- <option <? if ($pconfig['auth_algs'] == '2') echo "selected";?> value="2">Shared Key Authentication</option>
+ <option <? if ($pconfig['auth_algs'] == '1') echo "selected";?> value="1"><?=gettext("Open System Authentication"); ?></option>
+ <option <? if ($pconfig['auth_algs'] == '2') echo "selected";?> value="2"><?=gettext("Shared Key Authentication"); ?></option>
<option <? if ($pconfig['auth_algs'] == '3') echo "selected";?> value="3">Both</option>
</select>
- <br/>Note: Shared Key Authentication requires WEP.</br>
+ <br/><?=gettext("Note: Shared Key Authentication requires WEP"); ?>.</br>
</td>
</tr>
<tr>
- <td valign="top" class="vncell">WPA Pairwise</td>
+ <td valign="top" class="vncell"><?=gettext("WPA Pairwise"); ?></td>
<td class="vtable">
<select name="wpa_pairwise" class="formselect" id="wpa_pairwise">
- <option <? if ($pconfig['wpa_pairwise'] == 'CCMP TKIP') echo "selected";?> value="CCMP TKIP">Both</option>
- <option <? if ($pconfig['wpa_pairwise'] == 'CCMP') echo "selected";?> value="CCMP">AES (recommended)</option>
- <option <? if ($pconfig['wpa_pairwise'] == 'TKIP') echo "selected";?> value="TKIP">TKIP</option>
+ <option <? if ($pconfig['wpa_pairwise'] == 'CCMP TKIP') echo "selected";?> value="CCMP TKIP"><?=gettext("Both"); ?></option>
+ <option <? if ($pconfig['wpa_pairwise'] == 'CCMP') echo "selected";?> value="CCMP"><?=gettext("AES (recommended)"); ?></option>
+ <option <? if ($pconfig['wpa_pairwise'] == 'TKIP') echo "selected";?> value="TKIP"><?=gettext("TKIP"); ?></option>
</select>
</td>
</tr>
<tr>
- <td valign="top" class="vncell">Key Rotation</td>
+ <td valign="top" class="vncell"><?=gettext("Key Rotation"); ?></td>
<td class="vtable">
<input name="wpa_group_rekey" type="text" class="formfld unknown" id="wpa_group_rekey" size="30" value="<? echo $pconfig['wpa_group_rekey'] ? $pconfig['wpa_group_rekey'] : "60";?>">
- <br/>Allowed values are 1-9999 but should not be longer than Master Key Regeneration time.
+ <br/><?=gettext("Allowed values are 1-9999 but should not be longer than Master Key Regeneration time"); ?>.
</td>
</tr>
<tr>
- <td valign="top" class="vncell">Master Key Regeneration</td>
+ <td valign="top" class="vncell"><?=gettext("Master Key Regeneration"); ?></td>
<td class="vtable">
<input name="wpa_gmk_rekey" type="text" class="formfld" id="wpa_gmk_rekey" size="30" value="<? echo $pconfig['wpa_gmk_rekey'] ? $pconfig['wpa_gmk_rekey'] : "3600";?>">
- <br/>Allowed values are 1-9999 but should not be shorter than Key Rotation time.
+ <br/><?=gettext("Allowed values are 1-9999 but should not be shorter than Key Rotation time"); ?>.
</td>
</tr>
<tr>
- <td valign="top" class="vncell">Strict Key Regeneration</td>
+ <td valign="top" class="vncell"><?=gettext("Strict Key Regeneration"); ?></td>
<td class="vtable">
<input name="wpa_strict_rekey" type="checkbox" value="yes" class="formfld" id="wpa_strict_rekey" <? if ($pconfig['wpa_strict_rekey']) echo "checked"; ?>>
- <br/>Setting this option will force the AP to rekey whenever a client disassociates.
+ <br/><?=gettext("Setting this option will force the AP to rekey whenever a client disassociates"); ?>.
</td>
</tr>
<tr>
- <td valign="top" class="vncell">Enable IEEE802.1X Authentication</td>
+ <td valign="top" class="vncell"><?=gettext("Enable IEEE802.1X Authentication"); ?></td>
<td class="vtable">
<input name="ieee8021x" type="checkbox" value="yes" class="formfld" id="ieee8021x" <? if ($pconfig['ieee8021x']) echo "checked";?>>
- <br/>Setting this option will enable 802.1x authentication.
- <br/><span class="red"><strong>NOTE:</strong</span> this option requires checking the "Enable WPA box".
+ <br/><?=gettext("Setting this option will enable 802.1x authentication"); ?>.
+ <br/><span class="red"><strong><?=gettext("NOTE"); ?>:</strong</span> <?=gettext("this option requires checking the \"Enable WPA box\""); ?>.
</td>
</tr>
<tr>
- <td valign="top" class="vncell">802.1X Authentication Server IP Address</td>
+ <td valign="top" class="vncell"><?=gettext("802.1X Authentication Server IP Address"); ?></td>
<td class="vtable">
<input name="auth_server_addr" id="auth_server_addr" type="text" class="formfld unknown" size="66" value="<?=htmlspecialchars($pconfig['auth_server_addr']);?>">
- <br/>Enter the IP address of the 802.1X Authentication Server. This is commonly a Radius server (FreeRadius, Internet Authentication Services, etc.)
+ <br/><?=gettext("Enter the IP address of the 802.1X Authentication Server. This is commonly a Radius server (FreeRadius, Internet Authentication Services, etc.)"); ?>
</td>
</tr>
<tr>
- <td valign="top" class="vncell">802.1X Authentication Server Port</td>
+ <td valign="top" class="vncell">802.1X <?=gettext("Authentication Server Port"); ?></td>
<td class="vtable">
<input name="auth_server_port" id="auth_server_port" type="text" class="formfld unknown" size="66" value="<?=htmlspecialchars($pconfig['auth_server_port']);?>">
- <br/>Leave blank for the default 1812 port.
+ <br/><?=gettext("Leave blank for the default 1812 port"); ?>.
</td>
</tr>
<tr>
- <td valign="top" class="vncell">802.1X Authentication Server Shared Secret</td>
+ <td valign="top" class="vncell">802.1X <?=gettext("Authentication Server Shared Secret"); ?></td>
<td class="vtable">
<input name="auth_server_shared_secret" id="auth_server_shared_secret" type="text" class="formfld unknown" size="66" value="<?=htmlspecialchars($pconfig['auth_server_shared_secret']);?>">
<br/>
@@ -1869,30 +1869,30 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<td colspan="2" valign="top" height="16"></td>
</tr>
<tr>
- <td colspan="2" valign="top" class="listtopic">Private networks</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("Private networks"); ?></td>
</tr>
<tr>
<td valign="middle" class="vncell">&nbsp;</td>
<td class="vtable">
<a name="rfc1918"></a>
<input name="blockpriv" type="checkbox" id="blockpriv" value="yes" <?php if ($pconfig['blockpriv']) echo "checked"; ?>>
- <strong>Block private networks</strong><br>
- When set, this option blocks traffic from IP addresses that are reserved
- for private networks as per RFC 1918 (10/8, 172.16/12, 192.168/16) as
- well as loopback addresses (127/8).&nbsp;&nbsp; You should generally
- leave this option turned on, unless your WAN network lies in such
- a private address space, too.
+ <strong><?=gettext("Block private networks"); ?></strong><br>
+ <?=gettext("When set, this option blocks traffic from IP addresses that are reserved " .
+ "for private networks as per RFC 1918 (10/8, 172.16/12, 192.168/16) as"); ?>
+ <?=gettext("well as loopback addresses (127/8)"); ?>.&nbsp;&nbsp; <?=gettext("You should generally " .
+ "leave this option turned on, unless your WAN network lies in such " .
+ "a private address space, too"); ?>.
</td>
</tr>
<tr>
<td valign="middle" class="vncell">&nbsp;</td>
<td class="vtable">
<input name="blockbogons" type="checkbox" id="blockbogons" value="yes" <?php if ($pconfig['blockbogons']) echo "checked"; ?>>
- <strong>Block bogon networks</strong><br>
- When set, this option blocks traffic from IP addresses that are reserved
- (but not RFC 1918) or not yet assigned by IANA.&nbsp;&nbsp;
- Bogons are prefixes that should never appear in the Internet routing table,
- and obviously should not appear as the source address in any packets you receive.
+ <strong><?=gettext("Block bogon networks"); ?></strong><br>
+ <?=gettext("When set, this option blocks traffic from IP addresses that are reserved " .
+ "(but not RFC 1918) or not yet assigned by IANA"); ?>.&nbsp;&nbsp;
+ <?=gettext("Bogons are prefixes that should never appear in the Internet routing table, " .
+ "and obviously should not appear as the source address in any packets you receive"); ?>.
</td>
</tr>
</table> <!-- End "allcfg" table -->
@@ -1905,8 +1905,8 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
</td>
<td>
<br/>
- <input id="save" name="Submit" type="submit" class="formbtn" value="Save">
- <input id="cancel" type="button" class="formbtn" value="Cancel" onclick="history.back()">
+ <input id="save" name="Submit" type="submit" class="formbtn" value="<?=gettext("Save"); ?>">
+ <input id="cancel" type="button" class="formbtn" value="<?=gettext("Cancel"); ?>" onclick="history.back()">
<input name="if" type="hidden" id="if" value="<?=$if;?>">
<?php if ($wancfg['if'] == $a_ppps[$pppid]['if']) : ?>
<input name="ppp_port" type="hidden" value="<?=$pconfig['port'];?>">
diff --git a/usr/local/www/interfaces_assign.php b/usr/local/www/interfaces_assign.php
index 2c38e80..aef014a 100755
--- a/usr/local/www/interfaces_assign.php
+++ b/usr/local/www/interfaces_assign.php
@@ -40,7 +40,7 @@
##|*MATCH=interfaces_assign.php*
##|-PRIV
-$pgtitle = array("Interfaces", "Assign network ports");
+$pgtitle = array(gettext("Interfaces"),gettext("Assign network ports"));
$statusurl = "status_interfaces.php";
require("guiconfig.inc");
@@ -182,9 +182,9 @@ if ($_POST['apply']) {
/* Deliver error message for any port with more than one assignment */
foreach ($portifmap as $portname => $ifnames) {
if (count($ifnames) > 1) {
- $errstr = "Port " . $portname .
- " was assigned to " . count($ifnames) .
- " interfaces:";
+ $errstr = sprintf(gettext("Port '%s' ".
+ " was assigned to '%s'" .
+ " interfaces:"), $portname, count($ifnames));
foreach ($portifmap[$portname] as $ifn)
$errstr .= " " . $ifn;
@@ -246,11 +246,11 @@ if ($_GET['act'] == "del") {
$id = $_GET['id'];
if (link_interface_to_bridge($id))
- $input_errors[] = "The interface is part of a bridge. Please remove it from the bridge to continue";
+ $input_errors[] = gettext("The interface is part of a bridge. Please remove it from the bridge to continue");
else if (link_interface_to_gre($id))
- $input_errors[] = "The interface is part of a gre tunnel. Please delete the tunnel to continue";
+ $input_errors[] = gettext("The interface is part of a gre tunnel. Please delete the tunnel to continue");
else if (link_interface_to_gif($id))
- $input_errors[] = "The interface is part of a gif tunnel. Please delete the tunnel to continue";
+ $input_errors[] = gettext("The interface is part of a gif tunnel. Please delete the tunnel to continue");
else {
unset($config['interfaces'][$id]['enable']);
$realid = get_real_interface($id);
@@ -300,15 +300,15 @@ if ($_GET['act'] == "del") {
link_interface_to_vlans($realid, "update");
- $savemsg = "Interface has been deleted.";
+ $savemsg = gettext("Interface has been deleted.");
}
}
if ($_GET['act'] == "add") {
/* find next free optional interface number */
if(!$config['interfaces']['lan']) {
- $newifname = "lan";
- $descr = "LAN";
+ $newifname = gettext("lan");
+ $descr = gettext("LAN");
$config['interfaces'][$newifname] = array();
$config['interfaces'][$newifname]['descr'] = $descr;
} else {
@@ -317,7 +317,7 @@ if ($_GET['act'] == "add") {
break;
}
$newifname = 'opt' . $i;
- $descr = "OPT{$i}";
+ $descr = sprintf(gettext("OPT '%s'"),$i);
$config['interfaces'][$newifname] = array();
$config['interfaces'][$newifname]['descr'] = $descr;
}
@@ -348,7 +348,7 @@ if ($_GET['act'] == "add") {
write_config();
- $savemsg = "Interface has been added.";
+ $savemsg = gettext("Interface has been added.");
}
@@ -371,9 +371,9 @@ include("head.inc");
if(file_exists("/var/run/interface_mismatch_reboot_needed"))
if ($_POST)
- $savemsg = "Reboot is needed. Please apply the settings in order to reboot.";
+ $savemsg = gettext("Reboot is needed. Please apply the settings in order to reboot.");
else
- $savemsg = "Interface mismatch detected. Please resolve the mismatch and click Save. The firewall will reboot afterwards.";
+ $savemsg = gettext("Interface mismatch detected. Please resolve the mismatch and click Save. The firewall will reboot afterwards.");
?>
@@ -383,7 +383,7 @@ if(file_exists("/var/run/interface_mismatch_reboot_needed"))
<form action="interfaces_assign.php" method="post" name="iform" id="iform">
<?php if (file_exists("/tmp/reload_interfaces")): ?><p>
- <?php print_info_box_np("The interface configuration has been changed.<br>You must apply the changes in order for them to take effect.");?><br>
+ <?php print_info_box_np(gettext("The interface configuration has been changed.<br>You must apply the changes in order for them to take effect)."));?><br>
<?php elseif($savemsg): ?>
<?php print_info_box($savemsg); ?>
<?php endif; ?>
@@ -394,16 +394,16 @@ if(file_exists("/var/run/interface_mismatch_reboot_needed"))
<tr><td class="tabnavtbl">
<?php
$tab_array = array();
- $tab_array[0] = array("Interface assignments", true, "interfaces_assign.php");
- $tab_array[1] = array("Interface Groups", false, "interfaces_groups.php");
- $tab_array[2] = array("Wireless", false, "interfaces_wireless.php");
- $tab_array[3] = array("VLANs", false, "interfaces_vlan.php");
- $tab_array[4] = array("QinQs", false, "interfaces_qinq.php");
- $tab_array[5] = array("PPPs", false, "interfaces_ppps.php");
- $tab_array[7] = array("GRE", false, "interfaces_gre.php");
- $tab_array[8] = array("GIF", false, "interfaces_gif.php");
- $tab_array[9] = array("Bridges", false, "interfaces_bridge.php");
- $tab_array[10] = array("LAGG", false, "interfaces_lagg.php");
+ $tab_array[0] = array(gettext("Interface assignments"), true, "interfaces_assign.php");
+ $tab_array[1] = array(gettext("Interface Groups"), false, "interfaces_groups.php");
+ $tab_array[2] = array(gettext("Wireless"), false, "interfaces_wireless.php");
+ $tab_array[3] = array(gettext("VLANs"), false, "interfaces_vlan.php");
+ $tab_array[4] = array(gettext("QinQs"), false, "interfaces_qinq.php");
+ $tab_array[5] = array(gettext("PPPs"), false, "interfaces_ppps.php");
+ $tab_array[7] = array(gettext("GRE"), false, "interfaces_gre.php");
+ $tab_array[8] = array(gettext("GIF"), false, "interfaces_gif.php");
+ $tab_array[9] = array(gettext("Bridges"), false, "interfaces_bridge.php");
+ $tab_array[10] = array(gettext("LAGG"), false, "interfaces_lagg.php");
display_top_tabs($tab_array);
?>
</td></tr>
@@ -412,8 +412,8 @@ if(file_exists("/var/run/interface_mismatch_reboot_needed"))
<div id="mainarea">
<table class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
- <td class="listhdrr">Interface</td>
- <td class="listhdr">Network port</td>
+ <td class="listhdrr"><?=gettext("Interface"); ?></td>
+ <td class="listhdr"><?=gettext("Network port"); ?></td>
<td class="list">&nbsp;</td>
</tr>
<?php foreach ($config['interfaces'] as $ifname => $iface):
@@ -429,7 +429,7 @@ if(file_exists("/var/run/interface_mismatch_reboot_needed"))
<?php foreach ($portlist as $portname => $portinfo): ?>
<option value="<?=$portname;?>" <?php if ($portname == $iface['if']) echo " selected";?>>
<?php if ($portinfo['isvlan']) {
- $descr = "VLAN {$portinfo['tag']} on {$portinfo['if']}";
+ $descr = sprintf(gettext("VLAN '%s' on '%s'"),$portinfo['tag'],$portinfo['if']);
if ($portinfo['descr'])
$descr .= " (" . $portinfo['descr'] . ")";
echo htmlspecialchars($descr);
@@ -470,7 +470,7 @@ if(file_exists("/var/run/interface_mismatch_reboot_needed"))
</td>
<td valign="middle" class="list">
<?php if ($ifname != 'wan'): ?>
- <a href="interfaces_assign.php?act=del&id=<?=$ifname;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" title="delete interface" width="17" height="17" border="0"></a>
+ <a href="interfaces_assign.php?act=del&id=<?=$ifname;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" title=<?=gettext("delete interface"); ?> width="17" height="17" border="0"></a>
<?php endif; ?>
</td>
</tr>
@@ -479,7 +479,7 @@ if(file_exists("/var/run/interface_mismatch_reboot_needed"))
<tr>
<td class="list" colspan="2"></td>
<td class="list" nowrap>
- <a href="interfaces_assign.php?act=add"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" title="add interface" width="17" height="17" border="0"></a>
+ <a href="interfaces_assign.php?act=add"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" title=<?=gettext("add interface"); ?> width="17" height="17" border="0"></a>
</td>
</tr>
<?php else: ?>
@@ -490,14 +490,14 @@ if(file_exists("/var/run/interface_mismatch_reboot_needed"))
</table>
</div>
<br/>
-<input name="Submit" type="submit" class="formbtn" value="Save"><br><br>
+<input name="Submit" type="submit" class="formbtn" value="<?=gettext("Save"); ?>"><br><br>
<p>
</p>
<ul>
- <li><span class="vexpl">change the IP address of your computer</span></li>
- <li><span class="vexpl">renew its DHCP lease</span></li>
- <li><span class="vexpl">access the webConfigurator with the new IP address</span></li>
- <li><span class="vexpl">interfaces that are configured as members of a lagg(4) interface will not be shown.</span></li>
+ <li><span class="vexpl"><?=gettext("change the IP address of your computer"); ?></span></li>
+ <li><span class="vexpl"><?=gettext("renew its DHCP lease"); ?></span></li>
+ <li><span class="vexpl"><?=gettext("access the webConfigurator with the new IP address"); ?></span></li>
+ <li><span class="vexpl"><?=gettext("interfaces that are configured as members of a lagg(4) interface will not be shown."); ?></span></li>
</ul></td>
</tr>
</table>
diff --git a/usr/local/www/interfaces_bridge.php b/usr/local/www/interfaces_bridge.php
index e7aa71d..ad31e59 100644
--- a/usr/local/www/interfaces_bridge.php
+++ b/usr/local/www/interfaces_bridge.php
@@ -61,7 +61,7 @@ function bridge_inuse($num) {
if ($_GET['act'] == "del") {
/* check if still in use */
if (bridge_inuse($_GET['id'])) {
- $input_errors[] = "This bridge cannot be deleted because it is assigned as an interface.";
+ $input_errors[] = gettext("This bridge cannot be deleted because it is assigned as an interface.");
} else {
mwexec("/sbin/ifconfig " . $a_bridges[$_GET['id']]['bridgeif'] . " destroy");
unset($a_bridges[$_GET['id']]);
@@ -74,7 +74,7 @@ if ($_GET['act'] == "del") {
}
-$pgtitle = array("Interfaces","Bridge");
+$pgtitle = array(gettext("Interfaces"),gettext("Bridge"));
include("head.inc");
?>
@@ -86,16 +86,16 @@ include("head.inc");
<tr><td>
<?php
$tab_array = array();
- $tab_array[0] = array("Interface assignments", false, "interfaces_assign.php");
- $tab_array[1] = array("Interface Groups", false, "interfaces_groups.php");
- $tab_array[2] = array("Wireless", false, "interfaces_wireless.php");
- $tab_array[3] = array("VLANs", false, "interfaces_vlan.php");
- $tab_array[4] = array("QinQs", false, "interfaces_qinq.php");
- $tab_array[5] = array("PPPs", false, "interfaces_ppps.php");
- $tab_array[6] = array("GRE", false, "interfaces_gre.php");
- $tab_array[7] = array("GIF", false, "interfaces_gif.php");
- $tab_array[8] = array("Bridges", true, "interfaces_bridge.php");
- $tab_array[9] = array("LAGG", false, "interfaces_lagg.php");
+ $tab_array[0] = array(gettext("Interface assignments"), false, "interfaces_assign.php");
+ $tab_array[1] = array(gettext("Interface Groups"), false, "interfaces_groups.php");
+ $tab_array[2] = array(gettext("Wireless"), false, "interfaces_wireless.php");
+ $tab_array[3] = array(gettext("VLANs"), false, "interfaces_vlan.php");
+ $tab_array[4] = array(gettext("QinQs"), false, "interfaces_qinq.php");
+ $tab_array[5] = array(gettext("PPPs"), false, "interfaces_ppps.php");
+ $tab_array[6] = array(gettext("GRE"), false, "interfaces_gre.php");
+ $tab_array[7] = array(gettext("GIF"), false, "interfaces_gif.php");
+ $tab_array[8] = array(gettext("Bridges"), true, "interfaces_bridge.php");
+ $tab_array[9] = array(gettext("LAGG"), false, "interfaces_lagg.php");
display_top_tabs($tab_array);
?>
</td></tr>
@@ -104,9 +104,9 @@ include("head.inc");
<div id="mainarea">
<table class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
- <td width="20%" class="listhdrr">Interface</td>
- <td width="20%" class="listhdrr">Members</td>
- <td width="50%" class="listhdr">Description</td>
+ <td width="20%" class="listhdrr"><?=gettext("Interface"); ?></td>
+ <td width="20%" class="listhdrr"><?=gettext("Members"); ?></td>
+ <td width="50%" class="listhdr"><?=gettext("Description"); ?></td>
<td width="10%" class="list"></td>
</tr>
<?php $i = 0; $ifdescrs = get_configured_interface_with_descr();
@@ -132,7 +132,7 @@ include("head.inc");
<?=htmlspecialchars($bridge['descr']);?>&nbsp;
</td>
<td valign="middle" nowrap class="list"> <a href="interfaces_bridge_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a>
- &nbsp;<a href="interfaces_bridge.php?act=del&id=<?=$i;?>" onclick="return confirm('Do you really want to delete this bridge?')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
+ &nbsp;<a href="interfaces_bridge.php?act=del&id=<?=$i;?>" onclick="return confirm('<?=gettext("'Do you really want to delete this bridge?'"); ?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
</tr>
<?php $i++; endforeach; ?>
<tr>
@@ -141,9 +141,9 @@ include("head.inc");
</tr>
<tr>
<td colspan="3" class="list"><p class="vexpl"><span class="red"><strong>
- Note:<br>
+ <?=gettext("Note"); ?>:<br>
</strong></span>
- Here you can configure bridging of interfaces.
+ <?=gettext("Here you can configure bridging of interfaces"); ?>.
</td>
<td class="list">&nbsp;</td>
</tr>
diff --git a/usr/local/www/interfaces_bridge_edit.php b/usr/local/www/interfaces_bridge_edit.php
index 1b2b304..1a32ff5 100644
--- a/usr/local/www/interfaces_bridge_edit.php
+++ b/usr/local/www/interfaces_bridge_edit.php
@@ -104,45 +104,45 @@ if ($_POST) {
/* input validation */
$reqdfields = explode(" ", "members");
- $reqdfieldsn = explode(",", "Member Interfaces");
+ $reqdfieldsn = array(gettext("Member Interfaces"));
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
if ($_POST['maxage'] && !is_numeric($_POST['maxage']))
- $input_errors[] = "Maxage needs to be an integer between 6 and 40.";
+ $input_errors[] = gettext("Maxage needs to be an integer between 6 and 40.");
if ($_POST['maxaddr'] && !is_numeric($_POST['maxaddr']))
- $input_errors[] = "Maxaddr needs to be an integer.";
+ $input_errors[] = gettext("Maxaddr needs to be an integer.");
if ($_POST['timeout'] && !is_numeric($_POST['timeout']))
- $input_errors[] = "Timeout needs to be an integer.";
+ $input_errors[] = gettext("Timeout needs to be an integer.");
if ($_POST['fwdelay'] && !is_numeric($_POST['fwdelay']))
- $input_errors[] = "Forward Delay needs to be an integer between 4 and 30.";
+ $input_errors[] = gettext("Forward Delay needs to be an integer between 4 and 30.");
if ($_POST['hellotime'] && !is_numeric($_POST['hellotime']))
- $input_errors[] = "Hello time for STP needs to be an integer between 1 and 2.";
+ $input_errors[] = gettext("Hello time for STP needs to be an integer between 1 and 2.");
if ($_POST['priority'] && !is_numeric($_POST['priority']))
- $input_errors[] = "Priority for STP needs to be an integer between 0 and 61440.";
+ $input_errors[] = gettext("Priority for STP needs to be an integer between 0 and 61440.");
if ($_POST['holdcnt'] && !is_numeric($_POST['holdcnt']))
- $input_errors[] = "Transmit Hold Count for STP needs to be an integer between 1 and 10.";
+ $input_errors[] = gettext("Transmit Hold Count for STP needs to be an integer between 1 and 10.");
foreach ($ifacelist as $ifn => $ifdescr) {
if ($_POST[$ifn] <> "" && !is_numeric($_POST[$ifn]))
- $input_errors[] = "{$ifdescr} interface priority for STP needs to be an integer between 0 and 240.";
+ $input_errors[] = "{$ifdescr} " . gettext("interface priority for STP needs to be an integer between 0 and 240.");
}
$i = 0;
foreach ($ifacelist as $ifn => $ifdescr) {
if ($_POST["{$ifn}{$i}"] <> "" && !is_numeric($_POST["{$ifn}{$i}"]))
- $input_errors[] = "{$ifdescr} interface path cost for STP needs to be an integer between 1 and 200000000.";
+ $input_errors[] = "{$ifdescr} " . gettext("interface path cost for STP needs to be an integer between 1 and 200000000.");
$i++;
}
if (!is_array($_POST['members']) || count($_POST['members']) < 2)
- $input_errors[] = "You must select at least 2 member interfaces for a bridge.";
+ $input_errors[] = gettext("You must select at least 2 member interfaces for a bridge.");
if (is_array($_POST['members'])) {
foreach($_POST['members'] as $ifmembers) {
if (is_array($config['interfaces'][$ifmembers]['wireless']) &&
$config['interfaces'][$ifmembers]['wireless']['mode'] != "hostap")
- $input_errors[] = "Bridging a wireless interface is only possible in hostap mode.";
+ $input_errors[] = gettext("Bridging a wireless interface is only possible in hostap mode.");
if ($_POST['span'] != "none" && $_POST['span'] == $ifmembers)
- $input_errors[] = "Span interface cannot be part of the bridge. Remove the span interface from bridge members to continue.";
+ $input_errors[] = gettext("Span interface cannot be part of the bridge. Remove the span interface from bridge members to continue.");
}
}
@@ -199,7 +199,7 @@ if ($_POST) {
$bridge['bridgeif'] = $_POST['bridgeif'];
$bridge['bridgeif'] = interface_bridge_configure($bridge);
if ($bridge['bridgeif'] == "" || !stristr($bridge['bridgeif'], "bridge"))
- $input_errors[] = "Error occured creating interface, please retry.";
+ $input_errors[] = gettext("Error occured creating interface, please retry.");
else {
if (isset($id) && $a_bridges[$id])
$a_bridges[$id] = $bridge;
@@ -219,7 +219,7 @@ if ($_POST) {
}
}
-$pgtitle = array("Firewall","Bridge","Edit");
+$pgtitle = array(gettext("Firewall"),gettext("Bridge"),gettext("Edit"));
include("head.inc");
?>
@@ -246,10 +246,10 @@ function show_source_port_range() {
<form action="interfaces_bridge_edit.php" method="post" name="iform" id="iform">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">Bridge configuration</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("Bridge configuration"); ?></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">Member interfaces</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Member interfaces"); ?></td>
<td width="78%" class="vtable">
<select name="members[]" multiple="true" class="formselect" size="3">
<?php
@@ -262,11 +262,11 @@ function show_source_port_range() {
?>
</select>
<br/>
- <span class="vexpl">Interfaces participating in the bridge.</span>
+ <span class="vexpl"><?=gettext("Interfaces participating in the bridge."); ?></span>
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Description</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Description"); ?></td>
<td width="78%" class="vtable">
<input type="text" name="descr" id="descr" class="formfld unknown" size="50" value="<?=$pconfig['descr'];?>">
</td>
@@ -274,17 +274,17 @@ function show_source_port_range() {
<tr id="sprtable" name="sprtable">
<td></td>
<td>
- <p><input type="button" onClick="show_source_port_range()" value="Show advanced options"></p>
+ <p><input type="button" onClick="show_source_port_range()" value="<?=gettext("Show advanced options"); ?>"></p>
</td>
</tr>
<tr style="display:none" id="sprtable1" name="sprtable1">
<td valign="top" class="vncell" align="middle">RSTP/STP </td>
<td class="vtable">
<input type="checkbox" name="enablestp" id="enablestp" <?php if ($pconfig['enablestp']) echo "checked";?>>
- <span class="vexpl"><strong>Enable spanning tree options for this bridge. </strong></span>
+ <span class="vexpl"><strong><?=gettext("Enable spanning tree options for this bridge."); ?> </strong></span>
<br/><br/>
<table id="stpoptions" name="stpoptions" border="0" cellpadding="6" cellspacing="0">
- <tr><td valign="top" class="vncell" width="20%">Protocol</td>
+ <tr><td valign="top" class="vncell" width="20%"><?=gettext("Protocol"); ?></td>
<td class="vtable" width="80%">
<select name="proto" id="proto">
<?php
@@ -297,9 +297,9 @@ function show_source_port_range() {
?>
</select>
<br/>
- <span class="vexpl">Protocol used for spanning tree. </span></td>
+ <span class="vexpl"><?=gettext("Protocol used for spanning tree."); ?> </span></td>
</td></tr>
- <tr> <td valign="top" class="vncell" width="20%">STP interfaces</td>
+ <tr> <td valign="top" class="vncell" width="20%"><?=gettext("STP interfaces"); ?></td>
<td class="vtable" width="80%">
<select name="stp[]" class="formselect" multiple="true" size="3">
<?php
@@ -312,61 +312,61 @@ function show_source_port_range() {
?>
</select>
<br/>
- <span class="vexpl" >
- Enable Spanning Tree Protocol on interface. The if_bridge(4)
- driver has support for the IEEE 802.1D Spanning Tree Protocol
- (STP). STP is used to detect and remove loops in a
- network topology.
+ <span class="vexpl" >
+ <?=gettext("Enable Spanning Tree Protocol on interface. The if_bridge(4) " .
+ "driver has support for the IEEE 802.1D Spanning Tree Protocol " .
+ "(STP). STP is used to detect and remove loops in a " .
+ "network topology."); ?>
</span>
</td></tr>
- <tr><td valign="top" class="vncell" width="20%">Valid time</td>
+ <tr><td valign="top" class="vncell" width="20%"><?=gettext("Valid time"); ?></td>
<td class="vtable" width="80%">
- <input name="maxage" type="text" class="formfld unkown" id="maxage" size="8" value="<?=$pconfig['maxage'];?>"> seconds
+ <input name="maxage" type="text" class="formfld unkown" id="maxage" size="8" value="<?=$pconfig['maxage'];?>"> <?=gettext("seconds"); ?>
<br/>
<span class="vexpl">
- Set the time that a Spanning Tree Protocol configuration is
- valid. The default is 20 seconds. The minimum is 6 seconds and
- the maximum is 40 seconds.
+ <?=gettext("Set the time that a Spanning Tree Protocol configuration is " .
+ "valid. The default is 20 seconds. The minimum is 6 seconds and " .
+ "the maximum is 40 seconds."); ?>
</span>
</td></tr>
- <tr><td valign="top" class="vncell" width="20%">Forward time </td>
+ <tr><td valign="top" class="vncell" width="20%"><?=gettext("Forward time"); ?> </td>
<td class="vtable" width="80%">
- <input name="fwdelay" type="text" class="formfld unkown" id="fwdelay" size="8" value="<?=$pconfig['fwdelay'];?>"> seconds
+ <input name="fwdelay" type="text" class="formfld unkown" id="fwdelay" size="8" value="<?=$pconfig['fwdelay'];?>"> <?=gettext("seconds"); ?>
<br/>
<span class="vexpl">
- Set the time that must pass before an interface begins forwarding
- packets when Spanning Tree is enabled. The default is 15 seconds. The minimum is 4 seconds and the maximum is 30 seconds.
+ <?=gettext("Set the time that must pass before an interface begins forwarding " .
+ "packets when Spanning Tree is enabled. The default is 15 seconds. The minimum is 4 seconds and the maximum is 30 seconds."); ?>
</span>
</td></tr>
- <tr><td valign="top" class="vncell" width="20%">Hello time</td>
+ <tr><td valign="top" class="vncell" width="20%"><?=gettext("Hello time"); ?></td>
<td class="vtable" width="80%">
- <input name="hellotime" type="text" class="formfld unkown" size="8" id="hellotime" value="<?=$pconfig['hellotime'];?>"> seconds
+ <input name="hellotime" type="text" class="formfld unkown" size="8" id="hellotime" value="<?=$pconfig['hellotime'];?>"> <?=gettext("seconds"); ?>
<br/>
<span class="vexpl">
- Set the time between broadcasting of Spanning Tree Protocol configuration messages. The hello time may only be changed when
- operating in legacy STP mode. The default is 2 seconds. The minimum is 1 second and the maximum is 2 seconds.
+ <?=gettext("Set the time between broadcasting of Spanning Tree Protocol configuration messages. The hello time may only be changed when " .
+ "operating in legacy STP mode. The default is 2 seconds. The minimum is 1 second and the maximum is 2 seconds."); ?>
</span>
</td></tr>
- <tr><td valign="top" class="vncell" width="20%">Priority</td>
+ <tr><td valign="top" class="vncell" width="20%"><?=gettext("Priority"); ?></td>
<td class="vtable" width="80%">
<input name="priority" type="text" class="formfld unkown" id="priority" value="<?=$pconfig['priority'];?>">
<br/>
<span class="vexpl">
- Set the bridge priority for Spanning Tree. The default is 32768.
- The minimum is 0 and the maximum is 61440.
+ <?=gettext("Set the bridge priority for Spanning Tree. The default is 32768. " .
+ "The minimum is 0 and the maximum is 61440."); ?>
</span>
</td></tr>
- <tr><td valign="top" class="vncell" width="20%">Hold count</td>
+ <tr><td valign="top" class="vncell" width="20%"><?=gettext("Hold count"); ?></td>
<td class="vtable" width="80%">
<input name="holdcnt" type="text" class="formfld unkown" id="holdcnt" value="<?=$pconfig['holdcnt'];?>">
<br/>
<span class="vexpl">
- Set the transmit hold count for Spanning Tree. This is the num-
- ber of packets transmitted before being rate limited. The
- default is 6. The minimum is 1 and the maximum is 10.
+ <?=gettext("Set the transmit hold count for Spanning Tree. This is the num- " .
+ "ber of packets transmitted before being rate limited. The " .
+ "default is 6. The minimum is 1 and the maximum is 10."); ?>
</span>
</td></tr>
- <tr><td valign="top" class="vncell" width="20%">Priority</td>
+ <tr><td valign="top" class="vncell" width="20%"><?=gettext("Priority"); ?></td>
<td class="vtable" width="80%">
<table>
<?php foreach ($ifacelist as $ifn => $ifdescr)
@@ -375,11 +375,11 @@ function show_source_port_range() {
</table>
<br/>
<span class="vexpl" >
- Set the Spanning Tree priority of interface to value. The
- default is 128. The minimum is 0 and the maximum is 240.
+ <?=gettext("Set the Spanning Tree priority of interface to value. The " .
+ "default is 128. The minimum is 0 and the maximum is 240."); ?>
</span>
</td></tr>
- <tr><td valign="top" class="vncell" width="20%">Path cost</td>
+ <tr><td valign="top" class="vncell" width="20%"><?=gettext("Path cost"); ?></td>
<td class="vtable" width="80%">
<table>
<?php $i = 0; foreach ($ifacelist as $ifn => $ifdescr)
@@ -388,40 +388,40 @@ function show_source_port_range() {
</table>
<br/>
<span class="vexpl" >
- Set the Spanning Tree path cost of interface to value. The
- default is calculated from the link speed. To change a previously selected path cost back to automatic, set the cost to 0.
- The minimum is 1 and the maximum is 200000000.
+ <?=gettext("Set the Spanning Tree path cost of interface to value. The " .
+ "default is calculated from the link speed. To change a previously selected path cost back to automatic, set the cost to 0. ".
+ "The minimum is 1 and the maximum is 200000000."); ?>
</span>
</td></tr>
</table>
</tr>
<tr style="display:none" id="sprtable2" name="sprtable2">
- <td valign="top" class="vncell">Cache size</td>
+ <td valign="top" class="vncell"><?=gettext("Cache size"); ?></td>
<td class="vtable">
- <input name="maxaddr" size="10" type="text" class="formfld unkown" id="maxaddr" value="<?=$pconfig['maxaddr'];?>"> entries
+ <input name="maxaddr" size="10" type="text" class="formfld unkown" id="maxaddr" value="<?=$pconfig['maxaddr'];?>"> <?=gettext("entries"); ?>
<br/><span class="vexpl">
-Set the size of the bridge address cache to size. The default is
- 100 entries.
+<?=gettext("Set the size of the bridge address cache to size. The default is " .
+ ".100 entries."); ?>
</span>
</td>
</tr>
<tr style="display:none" id="sprtable3" name="sprtable3">
- <td valign="top" class="vncell">Cache entry expire time</td>
+ <td valign="top" class="vncell"><?=gettext("Cache entry expire time"); ?></td>
<td>
- <input name="timeout" type="text" class="formfld unkown" id="timeout" size="10" value="<?=$pconfig['timeout'];?>"> seconds
+ <input name="timeout" type="text" class="formfld unkown" id="timeout" size="10" value="<?=$pconfig['timeout'];?>"> <?=gettext("seconds"); ?>
<br/><span class="vexpl">
- Set the timeout of address cache entries to this number of seconds. If
- seconds is zero, then address cache entries will not be expired.
- The default is 240 seconds.
+ <?=gettext("Set the timeout of address cache entries to this number of seconds. If " .
+ "seconds is zero, then address cache entries will not be expired. " .
+ "The default is 240 seconds."); ?>
</span>
</td>
</tr>
<tr style="display:none" id="sprtable4" name="sprtable4">
- <td valign="top" class="vncell">Span port</td>
+ <td valign="top" class="vncell"><?=gettext("Span port"); ?></td>
<td class="vtable">
<select name="span" class="formselect" id="span">
- <option value="none" selected>None</option>
+ <option value="none" selected><?=gettext("None"); ?></option>
<?php
foreach ($ifacelist as $ifn => $ifdescr) {
echo "<option value=\"{$ifn}\"";
@@ -432,21 +432,21 @@ Set the size of the bridge address cache to size. The default is
?>
</select>
<br/><span class="vexpl">
- Add the interface named by interface as a span port on the
- bridge. Span ports transmit a copy of every frame received by
- the bridge. This is most useful for snooping a bridged network
- passively on another host connected to one of the span ports of
- the bridge.
+ <?=gettext("Add the interface named by interface as a span port on the " .
+ "bridge. Span ports transmit a copy of every frame received by " .
+ "the bridge. This is most useful for snooping a bridged network " .
+ "passively on another host connected to one of the span ports of " .
+ "the bridge."); ?>
</span>
<p class="vexpl"><span class="red"><strong>
- Note:<br>
+ <?=gettext("Note"); ?>:<br>
</strong></span>
- The span interface cannot be part of the bridge member interfaces.
+ <?=gettext("The span interface cannot be part of the bridge member interfaces."); ?>
</span>
</td>
</tr>
<tr style="display:none" id="sprtable5" name="sprtable5">
- <td valign="top" class="vncell">Edge ports</td>
+ <td valign="top" class="vncell"><?=gettext("Edge ports"); ?></td>
<td class="vtable">
<select name="edge[]" class="formselect" multiple="true" size="3">
<?php
@@ -460,13 +460,13 @@ Set the size of the bridge address cache to size. The default is
</select>
<br>
<span class="vexpl">
- Set interface as an edge port. An edge port connects directly to
- end stations and cannot create bridging loops in the network; this
- allows it to transition straight to forwarding.
+ <?=gettext("Set interface as an edge port. An edge port connects directly to " .
+ "end stations and cannot create bridging loops in the network; this " .
+ "allows it to transition straight to forwarding."); ?>
</span></td>
</tr>
<tr style="display:none" id="sprtable6" name="sprtable6">
- <td valign="top" class="vncell">Auto Edge ports</td>
+ <td valign="top" class="vncell"><?=gettext("Auto Edge ports"); ?></td>
<td class="vtable">
<select name="autoedge[]" class="formselect" multiple="true" size="3">
<?php
@@ -480,16 +480,16 @@ Set the size of the bridge address cache to size. The default is
</select>
<br>
<span class="vexpl">
- Allow interface to automatically detect edge status. This is the
- default for all interfaces added to a bridge.
+ <?=gettext("Allow interface to automatically detect edge status. This is the " .
+ "default for all interfaces added to a bridge."); ?>
<p class="vexpl"><span class="red"><strong>
- Note:<br>
+ <?=gettext("Note"); ?>:<br>
</strong></span>
- This will disable the autoedge status of interfaces.
+ <?=gettext("This will disable the autoedge status of interfaces."); ?>
</span></td>
</tr>
<tr style="display:none" id="sprtable7" name="sprtable7">
- <td valign="top" class="vncell">PTP ports</td>
+ <td valign="top" class="vncell"><?=gettext("PTP ports"); ?></td>
<td class="vtable">
<select name="ptp[]" class="formselect" multiple="true" size="3">
<?php
@@ -503,13 +503,13 @@ Set the size of the bridge address cache to size. The default is
</select>
<br>
<span class="vexpl">
- Set the interface as a point-to-point link. This is required for
- straight transitions to forwarding and should be enabled on a
- direct link to another RSTP-capable switch.
+ <?=gettext("Set the interface as a point-to-point link. This is required for " .
+ "straight transitions to forwarding and should be enabled on a " .
+ "direct link to another RSTP-capable switch."); ?>
</span></td>
</tr>
<tr style="display:none" id="sprtable8" name="sprtable8">
- <td valign="top" class="vncell">Auto PTP ports</td>
+ <td valign="top" class="vncell"><?=gettext("Auto PTP ports"); ?></td>
<td class="vtable">
<select name="autoptp[]" class="formselect" multiple="true" size="3">
<?php
@@ -523,17 +523,17 @@ Set the size of the bridge address cache to size. The default is
</select>
<br>
<span class="vexpl">
- Automatically detect the point-to-point status on interface by
- checking the full duplex link status. This is the default for
- interfaces added to the bridge.
+ <?=gettext("Automatically detect the point-to-point status on interface by " .
+ "checking the full duplex link status. This is the default for " .
+ "interfaces added to the bridge."); ?>
<p class="vexpl"><span class="red"><strong>
- Note:<br>
+ <?=gettext("Note"); ?>:<br>
</strong></span>
- The interfaces selected here will be removed from default autoedge status.
+ <?=gettext("The interfaces selected here will be removed from default autoedge status."); ?>
</span></td>
</tr>
<tr style="display:none" id="sprtable9" name="sprtable9">
- <td valign="top" class="vncell">Sticky ports</td>
+ <td valign="top" class="vncell"><?=gettext("Sticky ports"); ?></td>
<td class="vtable">
<select name="static[]" class="formselect" multiple="true" size="3">
<?php
@@ -547,14 +547,14 @@ Set the size of the bridge address cache to size. The default is
</select>
<br>
<span class="vexpl">
- Mark an interface as a "sticky" interface. Dynamically learned
- address entries are treated as static once entered into the
- cache. Sticky entries are never aged out of the cache or
- replaced, even if the address is seen on a different interface.
+ <?=gettext("Mark an interface as a \"sticky\" interface. Dynamically learned " .
+ "address entries are treated as static once entered into the " .
+ "cache. Sticky entries are never aged out of the cache or " .
+ "replaced, even if the address is seen on a different interface."); ?>
</span></td>
</tr>
<tr style="display:none" id="sprtable10" name="sprtable10">
- <td valign="top" class="vncell">Private ports</td>
+ <td valign="top" class="vncell"><?=gettext("Private ports"); ?></td>
<td class="vtable">
<select name="private[]" class="formselect" multiple="true" size="3">
<?php
@@ -568,15 +568,15 @@ Set the size of the bridge address cache to size. The default is
</select>
<br>
<span class="vexpl">
- Mark an interface as a "private" interface. A private interface does not forward any traffic to any other port that is also
- a private interface.
+ <?=gettext("Mark an interface as a \"private\" interface. A private interface does not forward any traffic to any other port that is also " .
+ "a private interface."); ?>
</span></td>
</tr>
<tr>
<td width="22%" valign="top">&nbsp;</td>
<td width="78%">
<input type="hidden" name="bridgeif" value="<?=$pconfig['bridgeif']; ?>">
- <input name="Submit" type="submit" class="formbtn" value="Save"> <input type="button" value="Cancel" onclick="history.back()">
+ <input name="Submit" type="submit" class="formbtn" value="<?=gettext("Save"); ?>"> <input type="button" value="<?=gettext("Cancel"); ?>" onclick="history.back()">
<?php if (isset($id) && $a_bridges[$id]): ?>
<input name="id" type="hidden" value="<?=$id;?>">
<?php endif; ?>
diff --git a/usr/local/www/interfaces_gif.php b/usr/local/www/interfaces_gif.php
index 92439fa..3c03ad5 100644
--- a/usr/local/www/interfaces_gif.php
+++ b/usr/local/www/interfaces_gif.php
@@ -61,7 +61,7 @@ function gif_inuse($num) {
if ($_GET['act'] == "del") {
/* check if still in use */
if (gif_inuse($_GET['id'])) {
- $input_errors[] = "This gif TUNNEL cannot be deleted because it is still being used as an interface.";
+ $input_errors[] = gettext("This gif TUNNEL cannot be deleted because it is still being used as an interface.");
} else {
mwexec("/sbin/ifconfig " . $a_gifs[$_GET['id']]['gifif'] . " destroy");
unset($a_gifs[$_GET['id']]);
@@ -73,7 +73,7 @@ if ($_GET['act'] == "del") {
}
}
-$pgtitle = array("Interfaces","GIF");
+$pgtitle = array(gettext("Interfaces"),gettext("GIF"));
include("head.inc");
?>
@@ -85,16 +85,16 @@ include("head.inc");
<tr><td>
<?php
$tab_array = array();
- $tab_array[0] = array("Interface assignments", false, "interfaces_assign.php");
- $tab_array[1] = array("Interface Groups", false, "interfaces_groups.php");
- $tab_array[2] = array("Wireless", false, "interfaces_wireless.php");
- $tab_array[3] = array("VLANs", false, "interfaces_vlan.php");
- $tab_array[4] = array("QinQs", false, "interfaces_qinq.php");
- $tab_array[5] = array("PPPs", false, "interfaces_ppps.php");
- $tab_array[6] = array("GRE", false, "interfaces_gre.php");
- $tab_array[7] = array("GIF", true, "interfaces_gif.php");
- $tab_array[8] = array("Bridges", false, "interfaces_bridge.php");
- $tab_array[9] = array("LAGG", false, "interfaces_lagg.php");
+ $tab_array[0] = array(gettext("Interface assignments"), false, "interfaces_assign.php");
+ $tab_array[1] = array(gettext("Interface Groups"), false, "interfaces_groups.php");
+ $tab_array[2] = array(gettext("Wireless"), false, "interfaces_wireless.php");
+ $tab_array[3] = array(gettext("VLANs"), false, "interfaces_vlan.php");
+ $tab_array[4] = array(gettext("QinQs"), false, "interfaces_qinq.php");
+ $tab_array[5] = array(gettext("PPPs"), false, "interfaces_ppps.php");
+ $tab_array[6] = array(gettext("GRE"), false, "interfaces_gre.php");
+ $tab_array[7] = array(gettext("GIF"), true, "interfaces_gif.php");
+ $tab_array[8] = array(gettext("Bridges"), false, "interfaces_bridge.php");
+ $tab_array[9] = array(gettext("LAGG"), false, "interfaces_lagg.php");
display_top_tabs($tab_array);
?>
</td></tr>
@@ -103,9 +103,9 @@ include("head.inc");
<div id="mainarea">
<table class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
- <td width="20%" class="listhdrr">Interface</td>
- <td width="20%" class="listhdrr">Tunnel to...</td>
- <td width="50%" class="listhdr">Description</td>
+ <td width="20%" class="listhdrr"><?=gettext("Interface"); ?></td>
+ <td width="20%" class="listhdrr"><?=gettext("Tunnel to"); ?>...</td>
+ <td width="50%" class="listhdr"><?=gettext("Description"); ?></td>
<td width="10%" class="list"></td>
</tr>
<?php $i = 0; foreach ($a_gifs as $gif): ?>
@@ -120,7 +120,7 @@ include("head.inc");
<?=htmlspecialchars($gif['descr']);?>&nbsp;
</td>
<td valign="middle" nowrap class="list"> <a href="interfaces_gif_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a>
- &nbsp;<a href="interfaces_gif.php?act=del&id=<?=$i;?>" onclick="return confirm('Do you really want to delete this gif tunnel?')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
+ &nbsp;<a href="interfaces_gif.php?act=del&id=<?=$i;?>" onclick="return confirm(gettext("'Do you really want to delete this gif tunnel?'"))"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
</tr>
<?php $i++; endforeach; ?>
<tr>
@@ -129,9 +129,9 @@ include("head.inc");
</tr>
<tr>
<td colspan="3" class="list"><p class="vexpl"><span class="red"><strong>
- Note:<br>
+ <?=gettext("Note"); ?>:<br>
</strong></span>
- GIF tunnels are configured here.
+ <?=gettext("GIF tunnels are configured here"); ?>.
</td>
<td class="list">&nbsp;</td>
</tr>
diff --git a/usr/local/www/interfaces_gif_edit.php b/usr/local/www/interfaces_gif_edit.php
index 908277f..fdde8d4 100644
--- a/usr/local/www/interfaces_gif_edit.php
+++ b/usr/local/www/interfaces_gif_edit.php
@@ -69,13 +69,13 @@ if ($_POST) {
/* input validation */
$reqdfields = explode(" ", "if tunnel-remote-addr tunnel-remote-net tunnel-local-addr");
- $reqdfieldsn = explode(",", "Parent interface,Local address, Remote tunnel address, Remote tunnel network, Local tunnel address");
+ $reqdfieldsn = array(gettext("Parent interface,Local address, Remote tunnel address, Remote tunnel network, Local tunnel address"));
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
if ((!is_ipaddr($_POST['tunnel-local-addr'])) || (!is_ipaddr($_POST['tunnel-remote-addr'])) ||
(!is_ipaddr($_POST['remote-addr']))) {
- $input_errors[] = "The tunnel local and tunnel remote fields must have valid IP addresses.";
+ $input_errors[] = gettext("The tunnel local and tunnel remote fields must have valid IP addresses.");
}
foreach ($a_gifs as $gif) {
@@ -83,7 +83,7 @@ if ($_POST) {
continue;
if (($gif['if'] == $_POST['if']) && ($gif['tunnel-remote-net'] == $_POST['tunnel-remote-net'])) {
- $input_errors[] = "A gif with the network {$gif['remote-network']} is already defined.";
+ $input_errors[] = sprintf(gettext("A gif with the network %s is already defined."), $gif['remote-network']);
break;
}
}
@@ -102,7 +102,7 @@ if ($_POST) {
$gif['gifif'] = interface_gif_configure($gif);
if ($gif['gifif'] == "" || !stristr($gif['gifif'], "gif"))
- $input_errors[] = "Error occured creating interface, please retry.";
+ $input_errors[] = gettext("Error occured creating interface, please retry.");
else {
if (isset($id) && $a_gifs[$id])
$a_gifs[$id] = $gif;
@@ -117,7 +117,7 @@ if ($_POST) {
}
}
-$pgtitle = array("Firewall","GIF","Edit");
+$pgtitle = array(gettext("Firewall"),gettext("GIF"),gettext("Edit"));
include("head.inc");
?>
@@ -128,10 +128,10 @@ include("head.inc");
<form action="interfaces_gif_edit.php" method="post" name="iform" id="iform">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">GIF configuration</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("GIF configuration"); ?></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">Parent interface</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Parent interface"); ?></td>
<td width="78%" class="vtable">
<select name="if" class="formselect">
<?php
@@ -145,24 +145,24 @@ include("head.inc");
?>
</select>
<br/>
- <span class="vexpl">The interface here servers as the local address to be used for the gif tunnel.</span></td>
+ <span class="vexpl"><?=gettext("The interface here servers as the local address to be used for the gif tunnel."); ?></span></td>
</tr>
<tr>
- <td valign="top" class="vncellreq">gif remote address</td>
+ <td valign="top" class="vncellreq"><?=gettext("gif remote address"); ?></td>
<td class="vtable">
<input name="remote-addr" type="text" class="formfld unknown" id="remote-addr" size="16" value="<?=$pconfig['remote-addr'];?>">
<br>
- <span class="vexpl">Peer address where encapsulated gif packets will be sent. </span></td>
+ <span class="vexpl"><?=gettext("Peer address where encapsulated gif packets will be sent. "); ?></span></td>
</tr>
<tr>
- <td valign="top" class="vncellreq">gif tunnel local address</td>
+ <td valign="top" class="vncellreq"><?=gettext("gif tunnel local address"); ?></td>
<td class="vtable">
<input name="tunnel-local-addr" type="text" class="formfld unknown" id="tunnel-local-addr" size="16" value="<?=$pconfig['tunnel-local-addr'];?>">
<br>
- <span class="vexpl">Local gif tunnel endpoint</span></td>
+ <span class="vexpl"><?=gettext("Local gif tunnel endpoint"); ?></span></td>
</tr>
<tr>
- <td valign="top" class="vncellreq">gif tunnel remote address </td>
+ <td valign="top" class="vncellreq"><?=gettext("gif tunnel remote address "); ?></td>
<td class="vtable">
<input name="tunnel-remote-addr" type="text" class="formfld unknown" id="tunnel-remote-addr" size="16" value="<?=$pconfig['tunnel-remote-addr'];?>">
<select name="tunnel-remote-net" class="formselect" id="tunnel-remote-net">
@@ -177,37 +177,37 @@ include("head.inc");
?>
</select>
<br/>
- <span class="vexpl">Remote gif address endpoint. The subnet part is used for the determinig the network that is tunneled.</span></td>
+ <span class="vexpl"><?=gettext("Remote gif address endpoint. The subnet part is used for the determinig the network that is tunneled."); ?></span></td>
</tr>
<tr>
- <td valign="top" class="vncell">Route caching </td>
+ <td valign="top" class="vncell"><?=gettext("Route caching "); ?></td>
<td class="vtable">
<input name="link0" type="checkbox" id="link0" <?if ($pconfig['link0']) echo "checked";?>>
<br>
- <span class="vexpl">Specify if route caching can be enabled. Be careful with these settings on dynamic networks. </span></td>
+ <span class="vexpl"><?=gettext("Specify if route caching can be enabled. Be careful with these settings on dynamic networks. "); ?></span></td>
</tr>
<tr>
- <td valign="top" class="vncell">ECN friendly behaviour</td>
+ <td valign="top" class="vncell"><?=gettext("ECN friendly behaviour"); ?></td>
<td class="vtable">
<input name="link1" type="checkbox" id="link1" <?if ($pconfig['link1']) echo "checked";?>>
<br>
<span class="vexpl">
- Note that the ECN friendly behavior violates RFC2893. This should be
- used in mutual agreement with the peer.
+ <?=gettext("Note that the ECN friendly behavior violates RFC2893. This should be " .
+ "used in mutual agreement with the peer."); ?>
</span></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Description</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Description"); ?></td>
<td width="78%" class="vtable">
<input name="descr" type="text" class="formfld unknown" id="descr" size="40" value="<?=htmlspecialchars($pconfig['descr']);?>">
- <br> <span class="vexpl">You may enter a description here
- for your reference (not parsed).</span></td>
+ <br> <span class="vexpl"><?=gettext("You may enter a description here " .
+ "for your reference (not parsed)."); ?></span></td>
</tr>
<tr>
<td width="22%" valign="top">&nbsp;</td>
<td width="78%">
<input type="hidden" name="gifif" value="<?=$pconfig['gifif']; ?>">
- <input name="Submit" type="submit" class="formbtn" value="Save"> <input type="button" value="Cancel" onclick="history.back()">
+ <input name="Submit" type="submit" class="formbtn" value="<?=gettext("Save"); ?>"> <input type="button" value="<?=gettext("Cancel"); ?>" onclick="history.back()">
<?php if (isset($id) && $a_gifs[$id]): ?>
<input name="id" type="hidden" value="<?=$id;?>">
<?php endif; ?>
diff --git a/usr/local/www/interfaces_gre.php b/usr/local/www/interfaces_gre.php
index a1a959e..de2992b 100644
--- a/usr/local/www/interfaces_gre.php
+++ b/usr/local/www/interfaces_gre.php
@@ -40,6 +40,7 @@
##|-PRIV
require("guiconfig.inc");
+require_once("functions.inc");
if (!is_array($config['gres']['gre']))
$config['gres']['gre'] = array();
@@ -61,7 +62,7 @@ function gre_inuse($num) {
if ($_GET['act'] == "del") {
/* check if still in use */
if (gre_inuse($_GET['id'])) {
- $input_errors[] = "This GRE tunnel cannot be deleted because it is still being used as an interface.";
+ $input_errors[] = gettext("This GRE tunnel cannot be deleted because it is still being used as an interface.");
} else {
mwexec("/sbin/ifconfig " . $a_gres[$_GET['id']]['greif'] . " destroy");
unset($a_gres[$_GET['id']]);
@@ -73,7 +74,7 @@ if ($_GET['act'] == "del") {
}
}
-$pgtitle = array("Interfaces","GRE");
+$pgtitle = array(gettext("Interfaces"),gettext("GRE"));
include("head.inc");
?>
@@ -85,16 +86,16 @@ include("head.inc");
<tr><td>
<?php
$tab_array = array();
- $tab_array[0] = array("Interface assignments", false, "interfaces_assign.php");
- $tab_array[1] = array("Interface Groups", false, "interfaces_groups.php");
- $tab_array[2] = array("Wireless", false, "interfaces_wireless.php");
- $tab_array[3] = array("VLANs", false, "interfaces_vlan.php");
- $tab_array[4] = array("QinQs", false, "interfaces_qinq.php");
- $tab_array[5] = array("PPPs", false, "interfaces_ppps.php");
- $tab_array[6] = array("GRE", true, "interfaces_gre.php");
- $tab_array[7] = array("GIF", false, "interfaces_gif.php");
- $tab_array[8] = array("Bridges", false, "interfaces_bridge.php");
- $tab_array[9] = array("LAGG", false, "interfaces_lagg.php");
+ $tab_array[0] = array(gettext("Interface assignments"), false, "interfaces_assign.php");
+ $tab_array[1] = array(gettext("Interface Groups"), false, "interfaces_groups.php");
+ $tab_array[2] = array(gettext("Wireless"), false, "interfaces_wireless.php");
+ $tab_array[3] = array(gettext("VLANs"), false, "interfaces_vlan.php");
+ $tab_array[4] = array(gettext("QinQs"), false, "interfaces_qinq.php");
+ $tab_array[5] = array(gettext("PPPs"), false, "interfaces_ppps.php");
+ $tab_array[6] = array(gettext("GRE"), true, "interfaces_gre.php");
+ $tab_array[7] = array(gettext("GIF"), false, "interfaces_gif.php");
+ $tab_array[8] = array(gettext("Bridges"), false, "interfaces_bridge.php");
+ $tab_array[9] = array(gettext("LAGG"), false, "interfaces_lagg.php");
display_top_tabs($tab_array);
?>
</td></tr>
@@ -103,9 +104,9 @@ include("head.inc");
<div id="mainarea">
<table class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
- <td width="20%" class="listhdrr">Interface</td>
- <td width="20%" class="listhdrr">Tunnel to...</td>
- <td width="50%" class="listhdr">Description</td>
+ <td width="20%" class="listhdrr"><?=gettext("Interface");?></td>
+ <td width="20%" class="listhdrr"><?=gettext("Tunnel to...");?></td>
+ <td width="50%" class="listhdr"><?=gettext("Description");?></td>
<td width="10%" class="list"></td>
</tr>
<?php $i = 0; foreach ($a_gres as $gre): ?>
@@ -120,7 +121,7 @@ include("head.inc");
<?=htmlspecialchars($gre['descr']);?>&nbsp;
</td>
<td valign="middle" nowrap class="list"> <a href="interfaces_gre_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a>
- &nbsp;<a href="interfaces_gre.php?act=del&id=<?=$i;?>" onclick="return confirm('Do you really want to delete this GRE tunnel?')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
+ &nbsp;<a href="interfaces_gre.php?act=del&id=<?=$i;?>" onclick="return confirm('<?=gettext("Do you really want to delete this GRE tunnel?");?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
</tr>
<?php $i++; endforeach; ?>
<tr>
@@ -129,7 +130,7 @@ include("head.inc");
</tr>
<tr>
<td class="tabcont" colspan="3">
- <p><span class="vexpl"><span class="red"><strong>Note:<br></strong></span>Here you can configure Generic Routing Encapsulation (GRE - RFC 2784) tunnels.</span></p>
+ <p><span class="vexpl"><span class="red"><strong><?=gettext("Note");?>:<br></strong></span><?=gettext("Here you can configure Generic Routing Encapsulation (GRE - RFC 2784) tunnels.");?></span></p>
</td>
</tr>
</table>
diff --git a/usr/local/www/interfaces_gre_edit.php b/usr/local/www/interfaces_gre_edit.php
index 1144bcd..3eae000 100644
--- a/usr/local/www/interfaces_gre_edit.php
+++ b/usr/local/www/interfaces_gre_edit.php
@@ -39,6 +39,7 @@
##|-PRIV
require("guiconfig.inc");
+require_once("functions.inc");
if (!is_array($config['gres']['gre']))
$config['gres']['gre'] = array();
@@ -70,13 +71,13 @@ if ($_POST) {
/* input validation */
$reqdfields = explode(" ", "if tunnel-remote-addr tunnel-remote-net tunnel-local-addr");
- $reqdfieldsn = explode(",", "Parent interface,Local address, Remote tunnel address, Remote tunnel network, Local tunnel address");
+ $reqdfieldsn = array(gettext("Parent interface"),gettext("Local address"),gettext("Remote tunnel address"),gettext("Remote tunnel network"), gettext("Local tunnel address"));
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
if ((!is_ipaddr($_POST['tunnel-local-addr'])) || (!is_ipaddr($_POST['tunnel-remote-addr'])) ||
(!is_ipaddr($_POST['remote-addr']))) {
- $input_errors[] = "The tunnel local and tunnel remote fields must have valid IP addresses.";
+ $input_errors[] = gettext("The tunnel local and tunnel remote fields must have valid IP addresses.");
}
foreach ($a_gres as $gre) {
@@ -84,7 +85,7 @@ if ($_POST) {
continue;
if (($gre['if'] == $_POST['if']) && ($gre['tunnel-remote-net'] == $_POST['tunnel-remote-net'])) {
- $input_errors[] = "A gre with the network {$gre['remote-network']} is already defined.";
+ $input_errors[] = sprintf(gettext("A gre with the network %s is already defined."),$gre['remote-network']);
break;
}
}
@@ -104,7 +105,7 @@ if ($_POST) {
$gre['greif'] = interface_gre_configure($gre);
if ($gre['greif'] == "" || !stristr($gre['greif'], "gre"))
- $input_errors[] = "Error occured creating interface, please retry.";
+ $input_errors[] = gettext("Error occured creating interface, please retry.");
else {
if (isset($id) && $a_gres[$id])
$a_gres[$id] = $gre;
@@ -119,7 +120,7 @@ if ($_POST) {
}
}
-$pgtitle = array("Firewall","GRE","Edit");
+$pgtitle = array(gettext("Firewall"),gettext("GRE"),gettext("Edit"));
include("head.inc");
?>
@@ -130,10 +131,10 @@ include("head.inc");
<form action="interfaces_gre_edit.php" method="post" name="iform" id="iform">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">GRE configuration</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("GRE configuration");?></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">Parent interface</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Parent interface");?></td>
<td width="78%" class="vtable">
<select name="if" class="formselect">
<?php
@@ -147,24 +148,24 @@ include("head.inc");
?>
</select>
<br/>
- <span class="vexpl">The interface here serves as the local address to be used for the GRE tunnel.</span></td>
+ <span class="vexpl"><?=gettext("The interface here serves as the local address to be used for the GRE tunnel.");?></span></td>
</tr>
<tr>
- <td valign="top" class="vncellreq">GRE remote address</td>
+ <td valign="top" class="vncellreq"><?=gettext("GRE remote address");?></td>
<td class="vtable">
<input name="remote-addr" type="text" class="formfld unknown" id="remote-addr" size="16" value="<?=$pconfig['remote-addr'];?>">
<br>
- <span class="vexpl">Peer address where encapsulated GRE packets will be sent </span></td>
+ <span class="vexpl"><?=gettext("Peer address where encapsulated GRE packets will be sent ");?></span></td>
</tr>
<tr>
- <td valign="top" class="vncellreq">GRE tunnel local address </td>
+ <td valign="top" class="vncellreq"><?=gettext("GRE tunnel local address ");?></td>
<td class="vtable">
<input name="tunnel-local-addr" type="text" class="formfld unknown" id="tunnel-local-addr" size="16" value="<?=$pconfig['tunnel-local-addr'];?>">
<br>
- <span class="vexpl">Local GRE tunnel endpoint</span></td>
+ <span class="vexpl"><?=gettext("Local GRE tunnel endpoint");?></span></td>
</tr>
<tr>
- <td valign="top" class="vncellreq">GRE tunnel remote address </td>
+ <td valign="top" class="vncellreq"><?=gettext("GRE tunnel remote address ");?></td>
<td class="vtable">
<input name="tunnel-remote-addr" type="text" class="formfld unknown" id="tunnel-remote-addr" size="16" value="<?=$pconfig['tunnel-remote-addr'];?>">
<select name="tunnel-remote-net" class="formselect" id="tunnel-remote-net">
@@ -179,46 +180,46 @@ include("head.inc");
?>
</select>
<br/>
- <span class="vexpl">Remote GRE address endpoint. The subnet part is used for the determining the network that is tunneled.</span></td>
+ <span class="vexpl"><?=gettext("Remote GRE address endpoint. The subnet part is used for the determining the network that is tunneled.");?></span></td>
</tr>
<tr>
- <td valign="top" class="vncell">Mobile tunnel</td>
+ <td valign="top" class="vncell"><?=gettext("Mobile tunnel");?></td>
<td class="vtable">
<input name="link0" type="checkbox" id="link0" <?if ($pconfig['link0']) echo "checked";?>>
<br>
- <span class="vexpl">Specify which encapsulation method the tunnel should use. </span></td>
+ <span class="vexpl"><?=gettext("Specify which encapsulation method the tunnel should use. ");?></span></td>
</tr>
<tr>
- <td valign="top" class="vncell">Route search type</td>
+ <td valign="top" class="vncell"><?=gettext("Route search type");?></td>
<td class="vtable">
<input name="link1" type="checkbox" id="link1" <?if ($pconfig['link1']) echo "checked";?>>
<br>
<span class="vexpl">
- For correct operation, the GRE device needs a route to the destination
- that is less specific than the one over the tunnel. (Basically, there
- needs to be a route to the decapsulating host that does not run over the
- tunnel, as this would be a loop.)
+ <?=gettext("For correct operation, the GRE device needs a route to the destination".
+ " that is less specific than the one over the tunnel. (Basically, there".
+ " needs to be a route to the decapsulating host that does not run over the".
+ " tunnel, as this would be a loop.");?>
</span></td>
</tr>
<tr>
- <td valign="top" class="vncell">WCCP version</td>
+ <td valign="top" class="vncell"><?=gettext("WCCP version");?></td>
<td class="vtable">
<input name="link2" type="checkbox" id="link2" <?if ($pconfig['link2']) echo "checked";?>>
<br>
- <span class="vexpl">Specify which WCCP encapsulation(version 1 or 2) method the tunnel should use</span></td>
+ <span class="vexpl"><?=gettext("Specify which WCCP encapsulation(version 1 or 2) method the tunnel should use");?></span></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Description</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Description");?></td>
<td width="78%" class="vtable">
<input name="descr" type="text" class="formfld unknown" id="descr" size="40" value="<?=htmlspecialchars($pconfig['descr']);?>">
- <br> <span class="vexpl">You may enter a description here
- for your reference (not parsed).</span></td>
+ <br> <span class="vexpl"><?=gettext("You may enter a description here".
+ " for your reference (not parsed).");?></span></td>
</tr>
<tr>
<td width="22%" valign="top">&nbsp;</td>
<td width="78%">
<input type="hidden" name="greif" value="<?=$pconfig['greif']; ?>">
- <input name="Submit" type="submit" class="formbtn" value="Save"> <input type="button" value="Cancel" onclick="history.back()">
+ <input name="Submit" type="submit" class="formbtn" value="<?=gettext("Save");?>"> <input type="button" value="<?=gettext("Cancel");?>" onclick="history.back()">
<?php if (isset($id) && $a_gres[$id]): ?>
<input name="id" type="hidden" value="<?=$id;?>">
<?php endif; ?>
diff --git a/usr/local/www/interfaces_groups.php b/usr/local/www/interfaces_groups.php
index 27a088a..54670b4 100755
--- a/usr/local/www/interfaces_groups.php
+++ b/usr/local/www/interfaces_groups.php
@@ -38,6 +38,7 @@
##|-PRIV
require("guiconfig.inc");
+require_once("functions.inc");
if (!is_array($config['ifgroups']['ifgroupentry']))
$config['ifgroups']['ifgroupentry'] = array();
@@ -59,7 +60,7 @@ if ($_GET['act'] == "del") {
}
}
-$pgtitle = array("Interfaces","Groups");
+$pgtitle = array(gettext("Interfaces"),gettext("Groups"));
include("head.inc");
?>
@@ -71,16 +72,16 @@ include("head.inc");
<tr><td>
<?php
$tab_array = array();
- $tab_array[0] = array("Interface assignments", false, "interfaces_assign.php");
- $tab_array[1] = array("Interface Groups", true, "interfaces_groups.php");
- $tab_array[2] = array("Wireless", false, "interfaces_wireless.php");
- $tab_array[3] = array("VLANs", false, "interfaces_vlan.php");
- $tab_array[4] = array("QinQs", false, "interfaces_qinq.php");
- $tab_array[5] = array("PPPs", false, "interfaces_ppps.php");
- $tab_array[6] = array("GRE", false, "interfaces_gre.php");
- $tab_array[7] = array("GIF", false, "interfaces_gif.php");
- $tab_array[8] = array("Bridges", false, "interfaces_bridge.php");
- $tab_array[9] = array("LAGG", false, "interfaces_lagg.php");
+ $tab_array[0] = array(gettext("Interface assignments"), false, "interfaces_assign.php");
+ $tab_array[1] = array(gettext("Interface Groups"), true, "interfaces_groups.php");
+ $tab_array[2] = array(gettext("Wireless"), false, "interfaces_wireless.php");
+ $tab_array[3] = array(gettext("VLANs"), false, "interfaces_vlan.php");
+ $tab_array[4] = array(gettext("QinQs"), false, "interfaces_qinq.php");
+ $tab_array[5] = array(gettext("PPPs"), false, "interfaces_ppps.php");
+ $tab_array[6] = array(gettext("GRE"), false, "interfaces_gre.php");
+ $tab_array[7] = array(gettext("GIF"), false, "interfaces_gif.php");
+ $tab_array[8] = array(gettext("Bridges"), false, "interfaces_bridge.php");
+ $tab_array[9] = array(gettext("LAGG"), false, "interfaces_lagg.php");
display_top_tabs($tab_array);
?>
</td></tr>
@@ -90,9 +91,9 @@ include("head.inc");
<table class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
- <td width="15%" class="listhdrr">Name</td>
- <td width="35%" class="listhdrr">Members</td>
- <td width="25%" class="listhdr">Description</td>
+ <td width="15%" class="listhdrr"><?=gettext("Name");?></td>
+ <td width="35%" class="listhdrr"><?=gettext("Members");?></td>
+ <td width="25%" class="listhdr"><?=gettext("Description");?></td>
<td width="5%" class="list"></td>
</tr>
<?php if (count ($a_ifgroups)):
@@ -123,8 +124,8 @@ include("head.inc");
<td valign="middle" nowrap class="list">
<table border="0" cellspacing="0" cellpadding="1">
<tr>
- <td valign="middle"><a href="interfaces_groups_edit.php?id=<?=$i;?>"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0" title="edit group"></a></td>
- <td><a href="interfaces_groups.php?act=del&id=<?=$i;?>" onclick="return confirm('Do you really want to delete this group? All elements that still use it will become invalid (e.g. filter rules)!')"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0" title="delete ifgroupentry"></a></td>
+ <td valign="middle"><a href="interfaces_groups_edit.php?id=<?=$i;?>"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0" title="<?=gettext("edit group");?>"></a></td>
+ <td><a href="interfaces_groups.php?act=del&id=<?=$i;?>" onclick="return confirm('<?=gettext("Do you really want to delete this group? All elements that still use it will become invalid (e.g. filter rules)!");?>')"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0" title="<?=gettext("delete ifgroupentry");?>"></a></td>
</tr>
</table>
</td>
@@ -136,7 +137,7 @@ include("head.inc");
<table border="0" cellspacing="0" cellpadding="1">
<tr>
<td valign="middle" width="17">&nbsp;</td>
- <td valign="middle"><a href="interfaces_groups_edit.php"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0" title="add a new group"></a></td>
+ <td valign="middle"><a href="interfaces_groups_edit.php"><img src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0" title="<?=gettext("add a new group");?>"></a></td>
</td>
</tr>
</table>
@@ -144,7 +145,7 @@ include("head.inc");
</tr>
<tr>
<td class="tabcont" colspan="3">
- <p><span class="vexpl"><span class="red"><strong>Note:<br></strong></span>Interface Groups allow you to create rules that apply to multiple interfaces without duplicating the rules. If you remove members from an interface group, the group rules no longer apply to that interface.</span></p>
+ <p><span class="vexpl"><span class="red"><strong><?=gettext("Note");?>:<br></strong></span><?=gettext("Interface Groups allow you to create rules that apply to multiple interfaces without duplicating the rules. If you remove members from an interface group, the group rules no longer apply to that interface.");?></span></p>
</td>
</tr>
</table>
diff --git a/usr/local/www/interfaces_groups_edit.php b/usr/local/www/interfaces_groups_edit.php
index 430bd7b..e1a9666 100755
--- a/usr/local/www/interfaces_groups_edit.php
+++ b/usr/local/www/interfaces_groups_edit.php
@@ -37,9 +37,11 @@
##|*MATCH=interfaces_groups_edit.php*
##|-PRIV
-$pgtitle = array("Interfaces","Groups", "Edit");
require("guiconfig.inc");
+require_once("functions.inc");
+
+$pgtitle = array(gettext("Interfaces"),gettext("Groups"),gettext("Edit"));
if (!is_array($config['ifgroups']['ifgroupentry']))
$config['ifgroups']['ifgroupentry'] = array();
@@ -66,10 +68,10 @@ if ($_POST) {
if (!isset($id)) {
foreach ($a_ifgroups as $groupentry)
if ($groupentry['ifname'] == $_POST['ifname'])
- $input_errors[] = "Group name already exists!";
+ $input_errors[] = gettext("Group name already exists!");
}
if (preg_match("/([^a-zA-Z])+/", $_POST['ifname'], $match))
- $input_errors[] = "Only letters A-Z are allowed as the group name.";
+ $input_errors[] = gettext("Only letters A-Z are allowed as the group name.");
$ifaces = get_configured_interface_with_descr();
foreach ($ifaces as $gif => $gdescr) {
@@ -205,33 +207,33 @@ function removeRow(el) {
<form action="interfaces_groups_edit.php" method="post" name="iform" id="iform">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">Interface Groups Edit</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("Interface Groups Edit");?></td>
</tr>
<tr>
- <td valign="top" class="vncellreq">Group Name</td>
+ <td valign="top" class="vncellreq"><?=gettext("Group Name");?></td>
<td class="vtable">
<input class="formfld unknown" name="ifname" id="ifname" value="<?=$pconfig['ifname'];?>" />
<br />
- No numbers or spaces are allowed. Only characters in a-zA-Z
+ <?=gettext("No numbers or spaces are allowed. Only characters in a-zA-Z");?>
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Description</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Description");?></td>
<td width="78%" class="vtable">
<input name="descr" type="text" class="formfld unknown" id="descr" size="40" value="<?=$pconfig['descr'];?>" />
<br />
<span class="vexpl">
- You may enter a description here for your reference (not parsed).
+ <?=gettext("You may enter a description here for your reference (not parsed).");?>
</span>
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq"><div id="membersnetworkport">Member (s)</div></td>
+ <td width="22%" valign="top" class="vncellreq"><div id="membersnetworkport"><?=gettext("Member (s)");?></div></td>
<td width="78%" class="vtable">
<table id="maintable">
<tbody>
<tr>
- <td><div id="onecolumn">Interface</div></td>
+ <td><div id="onecolumn"><?=gettext("Interface");?></div></td>
</tr>
<?php
@@ -257,7 +259,7 @@ function removeRow(el) {
</select>
</td>
<td>
- <input type="image" src="/themes/<?echo $g['theme'];?>/images/icons/icon_x.gif" onclick="removeRow(this); return false;" value="Delete" />
+ <input type="image" src="/themes/<?echo $g['theme'];?>/images/icons/icon_x.gif" onclick="removeRow(this); return false;" value="<?=gettext("Delete");?>" />
</td>
</tr>
<?php
@@ -272,15 +274,15 @@ function removeRow(el) {
</tfoot>
</table>
<a onclick="javascript:addRowTo('maintable'); return false;" href="#">
- <img border="0" src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" alt="" title="add another entry" />
+ <img border="0" src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" alt="" title="<?=gettext("add another entry");?>" />
</a>
</td>
</tr>
<tr>
<td width="22%" valign="top">&nbsp;</td>
<td width="78%">
- <input id="submit" name="submit" type="submit" class="formbtn" value="Save" />
- <a href="interfaces_groups.php"><input id="cancelbutton" name="cancelbutton" type="button" class="formbtn" value="Cancel" /></a>
+ <input id="submit" name="submit" type="submit" class="formbtn" value="<?=gettext("Save");?>" />
+ <a href="interfaces_groups.php"><input id="cancelbutton" name="cancelbutton" type="button" class="formbtn" value="<?=gettext("Cancel");?>" /></a>
<?php if (isset($id) && $a_ifgroups[$id]): ?>
<input name="id" type="hidden" value="<?=$id;?>" />
<?php endif; ?>
diff --git a/usr/local/www/interfaces_lagg.php b/usr/local/www/interfaces_lagg.php
index f09c59e..9cabb00 100644
--- a/usr/local/www/interfaces_lagg.php
+++ b/usr/local/www/interfaces_lagg.php
@@ -67,7 +67,7 @@ function lagg_inuse($num) {
if ($_GET['act'] == "del") {
/* check if still in use */
if (lagg_inuse($_GET['id'])) {
- $input_errors[] = "This LAGG interface cannot be deleted because it is still being used.";
+ $input_errors[] = gettext("This LAGG interface cannot be deleted because it is still being used.");
} else {
mwexec_bg("/sbin/ifconfig " . $a_laggs[$_GET['id']]['laggif'] . " destroy");
unset($a_laggs[$_GET['id']]);
@@ -79,7 +79,7 @@ if ($_GET['act'] == "del") {
}
}
-$pgtitle = array("Interfaces","LAGG");
+$pgtitle = array(gettext("Interfaces"),gettext("LAGG"));
include("head.inc");
?>
@@ -91,16 +91,16 @@ include("head.inc");
<tr><td>
<?php
$tab_array = array();
- $tab_array[0] = array("Interface assignments", false, "interfaces_assign.php");
- $tab_array[1] = array("Interface Groups", false, "interfaces_groups.php");
- $tab_array[2] = array("Wireless", false, "interfaces_wireless.php");
- $tab_array[3] = array("VLANs", false, "interfaces_vlan.php");
- $tab_array[4] = array("QinQs", false, "interfaces_qinq.php");
- $tab_array[5] = array("PPPs", false, "interfaces_ppps.php");
- $tab_array[6] = array("GRE", false, "interfaces_gre.php");
- $tab_array[7] = array("GIF", false, "interfaces_gif.php");
- $tab_array[8] = array("Bridges", false, "interfaces_bridge.php");
- $tab_array[9] = array("LAGG", true, "interfaces_lagg.php");
+ $tab_array[0] = array(gettext("Interface assignments"), false, "interfaces_assign.php");
+ $tab_array[1] = array(gettext("Interface Groups"), false, "interfaces_groups.php");
+ $tab_array[2] = array(gettext("Wireless"), false, "interfaces_wireless.php");
+ $tab_array[3] = array(gettext("VLANs"), false, "interfaces_vlan.php");
+ $tab_array[4] = array(gettext("QinQs"), false, "interfaces_qinq.php");
+ $tab_array[5] = array(gettext("PPPs"), false, "interfaces_ppps.php");
+ $tab_array[6] = array(gettext("GRE"), false, "interfaces_gre.php");
+ $tab_array[7] = array(gettext("GIF"), false, "interfaces_gif.php");
+ $tab_array[8] = array(gettext("Bridges"), false, "interfaces_bridge.php");
+ $tab_array[9] = array(gettext("LAGG"), true, "interfaces_lagg.php");
display_top_tabs($tab_array);
?>
</td></tr>
@@ -109,9 +109,9 @@ include("head.inc");
<div id="mainarea">
<table class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
- <td width="20%" class="listhdrr">Interface</td>
- <td width="20%" class="listhdrr">Members</td>
- <td width="50%" class="listhdr">Description</td>
+ <td width="20%" class="listhdrr"><?=gettext("Interface"); ?></td>
+ <td width="20%" class="listhdrr"><?=gettext("Members"); ?></td>
+ <td width="50%" class="listhdr"><?=gettext("Description"); ?></td>
<td width="10%" class="list"></td>
</tr>
<?php $i = 0; foreach ($a_laggs as $lagg): ?>
@@ -135,9 +135,9 @@ include("head.inc");
</tr>
<tr>
<td colspan="3" class="list"><p class="vexpl"><span class="red"><strong>
- Note:<br>
+ <?=gettext("Note"); ?>:<br>
</strong></span>
- LAGG allows for link aggregation, bonding and fault tolerance. Only unassigned interfaces can be added to LAGG.
+ <?=gettext("LAGG allows for link aggregation, bonding and fault tolerance. Only unassigned interfaces can be added to LAGG"); ?>.
</td>
<td class="list">&nbsp;</td>
</tr>
diff --git a/usr/local/www/interfaces_lagg_edit.php b/usr/local/www/interfaces_lagg_edit.php
index 8b67ab6..124c6ea 100644
--- a/usr/local/www/interfaces_lagg_edit.php
+++ b/usr/local/www/interfaces_lagg_edit.php
@@ -76,7 +76,7 @@ if ($_POST) {
/* input validation */
$reqdfields = explode(" ", "members proto");
- $reqdfieldsn = explode(",", "Member interfaces, Lagg protocol");
+ $reqdfieldsn = array(",", gettext("Member interfaces"), gettext("Lagg protocol"));
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
@@ -89,7 +89,7 @@ if ($_POST) {
$lagg['laggif'] = interface_lagg_configure($lagg);
if ($lagg['laggif'] == "" || !stristr($lagg['laggif'], "lagg"))
- $input_errors[] = "Error occured creating interface, please retry.";
+ $input_errors[] = gettext("Error occured creating interface, please retry.");
else {
if (isset($id) && $a_laggs[$id])
$a_laggs[$id] = $lagg;
@@ -108,7 +108,7 @@ if ($_POST) {
}
}
-$pgtitle = array("Firewall","LAGG","Edit");
+$pgtitle = array(gettext("Firewall"),gettext("LAGG"),gettext("Edit"));
include("head.inc");
?>
@@ -119,10 +119,10 @@ include("head.inc");
<form action="interfaces_lagg_edit.php" method="post" name="iform" id="iform">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">LAGG configuration</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("LAGG configuration"); ?></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">Parent interface</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Parent interface"); ?></td>
<td width="78%" class="vtable">
<select name="members[]" multiple="true" size="4" class="formselect">
<?php
@@ -137,10 +137,10 @@ include("head.inc");
?>
</select>
<br/>
- <span class="vexpl">Choose the members that will be used for the link aggregation.</span></td>
+ <span class="vexpl"><?=gettext("Choose the members that will be used for the link aggregation"); ?>.</span></td>
</tr>
<tr>
- <td valign="top" class="vncellreq">Lag proto</td>
+ <td valign="top" class="vncellreq"><?=gettext("Lag proto"); ?></td>
<td class="vtable">
<select name="proto" class="formselect" id="proto">
<?php
@@ -156,57 +156,57 @@ include("head.inc");
<span class="vexpl">
<ul>
<li>
- <b>failover</b><br/>
- Sends and receives traffic only through the master port. If
- the master port becomes unavailable, the next active port is
- used. The first interface added is the master port; any
- interfaces added after that are used as failover devices.
+ <b><?=gettext("failover"); ?></b><br/>
+ <?=gettext("Sends and receives traffic only through the master port. If " .
+ "the master port becomes unavailable, the next active port is " .
+ "used. The first interface added is the master port; any " .
+ "interfaces added after that are used as failover devices."); ?>
</li><li>
- <b>fec</b><br/> Supports Cisco EtherChannel. This is a static setup and
- does not negotiate aggregation with the peer or exchange
- frames to monitor the link.
+ <b><?=gettext("fec"); ?></b><br/> <?=gettext("Supports Cisco EtherChannel. This is a static setup and " .
+ "does not negotiate aggregation with the peer or exchange " .
+ "frames to monitor the link."); ?>
</li><li>
- <b>lacp</b><br/> Supports the IEEE 802.3ad Link Aggregation Control Protocol
- (LACP) and the Marker Protocol. LACP will negotiate a set
- of aggregable links with the peer in to one or more Link
- Aggregated Groups. Each LAG is composed of ports of the
- same speed, set to full-duplex operation. The traffic will
- be balanced across the ports in the LAG with the greatest
- total speed, in most cases there will only be one LAG which
- contains all ports. In the event of changes in physical
- connectivity, Link Aggregation will quickly converge to a
- new configuration.
+ <b><?=gettext("lacp"); ?></b><br/> <?=gettext("Supports the IEEE 802.3ad Link Aggregation Control Protocol " .
+ "(LACP) and the Marker Protocol. LACP will negotiate a set " .
+ "of aggregable links with the peer in to one or more Link " .
+ "Aggregated Groups. Each LAG is composed of ports of the " .
+ "same speed, set to full-duplex operation. The traffic will " .
+ "be balanced across the ports in the LAG with the greatest " .
+ "total speed, in most cases there will only be one LAG which " .
+ "contains all ports. In the event of changes in physical " .
+ "connectivity, Link Aggregation will quickly converge to a " .
+ "new configuration."); ?>
</li><li>
- <b>loadbalance</b><br/> Balances outgoing traffic across the active ports based on
- hashed protocol header information and accepts incoming
- traffic from any active port. This is a static setup and
- does not negotiate aggregation with the peer or exchange
- frames to monitor the link. The hash includes the Ethernet
- source and destination address, and, if available, the VLAN
- tag, and the IP source and destination address.
+ <b><?=gettext("loadbalance"); ?></b><br/> <?=gettext("Balances outgoing traffic across the active ports based on " .
+ "hashed protocol header information and accepts incoming " .
+ "traffic from any active port. This is a static setup and " .
+ "does not negotiate aggregation with the peer or exchange " .
+ "frames to monitor the link. The hash includes the Ethernet " .
+ "source and destination address, and, if available, the VLAN " .
+ "tag, and the IP source and destination address") ?>.
</li><li>
- <b>roundrobin</b><br/> Distributes outgoing traffic using a round-robin scheduler
- through all active ports and accepts incoming traffic from
- any active port.
+ <b><?=gettext("roundrobin"); ?></b><br/> <?=gettext("Distributes outgoing traffic using a round-robin scheduler " .
+ "through all active ports and accepts incoming traffic from " .
+ "any active port"); ?>.
</li><li>
- <b>none</b><br/> This protocol is intended to do nothing: it disables any
- traffic without disabling the lagg interface itself.
+ <b><?=gettext("none"); ?></b><br/> <?=gettext("This protocol is intended to do nothing: it disables any " .
+ "traffic without disabling the lagg interface itself"); ?>.
</li>
</ul>
</span></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Description</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Description"); ?></td>
<td width="78%" class="vtable">
<input name="descr" type="text" class="formfld unknown" id="descr" size="40" value="<?=htmlspecialchars($pconfig['descr']);?>">
- <br> <span class="vexpl">You may enter a description here
- for your reference (not parsed).</span></td>
+ <br> <span class="vexpl"><?=gettext("You may enter a description here " .
+ "for your reference (not parsed)"); ?>.</span></td>
</tr>
<tr>
<td width="22%" valign="top">&nbsp;</td>
<td width="78%">
<input type="hidden" name="laggif" value="<?=$pconfig['laggif']; ?>">
- <input name="Submit" type="submit" class="formbtn" value="Save"> <input type="button" value="Cancel" onclick="history.back()">
+ <input name="Submit" type="submit" class="formbtn" value="<?=gettext("Save"); ?>"> <input type="button" value="<?=gettext("Cancel"); ?>" onclick="history.back()">
<?php if (isset($id) && $a_laggs[$id]): ?>
<input name="id" type="hidden" value="<?=$id;?>">
<?php endif; ?>
diff --git a/usr/local/www/interfaces_ppps.php b/usr/local/www/interfaces_ppps.php
index e6d4880..01dcdb5 100644
--- a/usr/local/www/interfaces_ppps.php
+++ b/usr/local/www/interfaces_ppps.php
@@ -41,6 +41,7 @@
##|-PRIV
require("guiconfig.inc");
+require_once("functions.inc");
if (!is_array($config['ppps']['ppp']))
$config['ppps']['ppp'] = array();
@@ -60,7 +61,7 @@ function ppp_inuse($num) {
if ($_GET['act'] == "del") {
/* check if still in use */
if (ppp_inuse($_GET['id'])) {
- $input_errors[] = "This point-to-point link cannot be deleted because it is still being used as an interface.";
+ $input_errors[] = gettext("This point-to-point link cannot be deleted because it is still being used as an interface.");
} else {
unset($a_ppps[$_GET['id']]['pppoe-reset-type']);
handle_pppoe_reset($a_ppps[$_GET['id']]);
@@ -71,7 +72,7 @@ if ($_GET['act'] == "del") {
}
}
-$pgtitle = "Interfaces: PPPs";
+$pgtitle = gettext("Interfaces: PPPs");
include("head.inc");
?>
@@ -83,16 +84,16 @@ include("head.inc");
<tr><td>
<?php
$tab_array = array();
- $tab_array[0] = array("Interface assignments", false, "interfaces_assign.php");
- $tab_array[1] = array("Interface Groups", false, "interfaces_groups.php");
- $tab_array[2] = array("Wireless", false, "interfaces_wireless.php");
- $tab_array[3] = array("VLANs", false, "interfaces_vlan.php");
- $tab_array[4] = array("QinQs", false, "interfaces_qinq.php");
- $tab_array[5] = array("PPPs", true, "interfaces_ppps.php");
- $tab_array[6] = array("GRE", false, "interfaces_gre.php");
- $tab_array[7] = array("GIF", false, "interfaces_gif.php");
- $tab_array[8] = array("Bridges", false, "interfaces_bridge.php");
- $tab_array[9] = array("LAGG", false, "interfaces_lagg.php");
+ $tab_array[0] = array(gettext("Interface assignments"), false, "interfaces_assign.php");
+ $tab_array[1] = array(gettext("Interface Groups"), false, "interfaces_groups.php");
+ $tab_array[2] = array(gettext("Wireless"), false, "interfaces_wireless.php");
+ $tab_array[3] = array(gettext("VLANs"), false, "interfaces_vlan.php");
+ $tab_array[4] = array(gettext("QinQs"), false, "interfaces_qinq.php");
+ $tab_array[5] = array(gettext("PPPs"), true, "interfaces_ppps.php");
+ $tab_array[6] = array(gettext("GRE"), false, "interfaces_gre.php");
+ $tab_array[7] = array(gettext("GIF"), false, "interfaces_gif.php");
+ $tab_array[8] = array(gettext("Bridges"), false, "interfaces_bridge.php");
+ $tab_array[9] = array(gettext("LAGG"), false, "interfaces_lagg.php");
display_top_tabs($tab_array);
?>
</td></tr>
@@ -101,9 +102,9 @@ include("head.inc");
<div id="mainarea">
<table class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
- <td width="20%" class="listhdrr">Interface</td>
- <td width="20%" class="listhdrr">Interface(s)/Port(s)</td>
- <td width="40%" class="listhdr">Description</td>
+ <td width="20%" class="listhdrr"><?=gettext("Interface");?></td>
+ <td width="20%" class="listhdrr"><?=gettext("Interface(s)/Port(s)");?></td>
+ <td width="40%" class="listhdr"><?=gettext("Description");?></td>
<td width="10%" class="list"></td>
</tr>
<?php $i = 0; foreach ($a_ppps as $id => $ppp): ?>
@@ -125,7 +126,7 @@ include("head.inc");
<?=htmlspecialchars($ppp['descr']);?>&nbsp;
</td>
<td valign="middle" nowrap class="list"> <a href="interfaces_ppps_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a>
- &nbsp;<a href="interfaces_ppps.php?act=del&id=<?=$i;?>" onclick="return confirm('Do you really want to delete this PPP interface?')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
+ &nbsp;<a href="interfaces_ppps.php?act=del&id=<?=$i;?>" onclick="return confirm('<?=gettext("Do you really want to delete this PPP interface?");?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
</tr>
<?php $i++; endforeach; ?>
<tr>
diff --git a/usr/local/www/interfaces_ppps_edit.php b/usr/local/www/interfaces_ppps_edit.php
index f218f3c..391f3f2 100644
--- a/usr/local/www/interfaces_ppps_edit.php
+++ b/usr/local/www/interfaces_ppps_edit.php
@@ -175,17 +175,17 @@ if ($_POST) {
/* input validation */
switch($_POST['type']) {
case "ppp":
- $reqdfields = explode(" ", "interfaces phone");
- $reqdfieldsn = explode(",", "Link Interface(s),Phone Number");
+ $reqdfields = explode("interfaces phone");
+ $reqdfieldsn = array(gettext("Link Interface(s)"),gettext("Phone Number"));
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
break;
case "pppoe":
if ($_POST['ondemand']) {
$reqdfields = explode(" ", "interfaces username password ondemand idletimeout");
- $reqdfieldsn = explode(",", "Link Interface(s),Username,Password,Dial on demand,Idle timeout value");
+ $reqdfieldsn = array(gettext("Link Interface(s)"),gettext("Username"),gettext("Password"),gettext("Dial on demand"),gettext("Idle timeout value"));
} else {
$reqdfields = explode(" ", "interfaces username password");
- $reqdfieldsn = explode(",", "Link Interface(s),Username,Password");
+ $reqdfieldsn = array(gettext("Link Interface(s)"),gettext("Username"),gettext("Password"));
}
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
break;
@@ -193,23 +193,23 @@ if ($_POST) {
case "pptp":
if ($_POST['ondemand']) {
$reqdfields = explode(" ", "interfaces username password localip subnet gateway ondemand idletimeout");
- $reqdfieldsn = explode(",", "Link Interface(s),Username,Password,Local IP address,Subnet,Remote IP address,Dial on demand,Idle timeout value");
+ $reqdfieldsn = array(gettext("Link Interface(s)"),gettext("Username"),gettext("Password"),gettext("Local IP address"),gettext("Subnet"),gettext("Remote IP address"),gettext("Dial on demand"),gettext("Idle timeout value"));
} else {
$reqdfields = explode(" ", "interfaces username password localip subnet gateway");
- $reqdfieldsn = explode(",", "Link Interface(s),Username,Password,Local IP address,Subnet,Remote IP address");
+ $reqdfieldsn = array(gettext("Link Interface(s)"),gettext("Username"),gettext("Password"),gettext("Local IP address"),gettext("Subnet"),gettext("Remote IP address"));
}
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
break;
default:
- $input_errors[] = "Please choose a Link Type.";
+ $input_errors[] = gettext("Please choose a Link Type.");
break;
}
if ($_POST['type'] == "ppp" && count($_POST['interfaces']) > 1)
- $input_errors[] = "Multilink connections (MLPPP) using the PPP link type is not currently supported. Please select only one Link Interface.";
+ $input_errors[] = gettext("Multilink connections (MLPPP) using the PPP link type is not currently supported. Please select only one Link Interface.");
if (($_POST['provider'] && !is_domain($_POST['provider'])))
- $input_errors[] = "The service name contains invalid characters.";
+ $input_errors[] = gettext("The service name contains invalid characters.");
if (($_POST['idletimeout'] != "") && !is_numericint($_POST['idletimeout']))
- $input_errors[] = "The idle timeout value must be an integer.";
+ $input_errors[] = gettext("The idle timeout value must be an integer.");
if ($_POST['pppoe-reset-type'] == "custom" && $_POST['pppoe_resethour'] <> "" && !is_numericint($_POST['pppoe_resethour']) &&
$_POST['pppoe_resethour'] >= 0 && $_POST['pppoe_resethour'] <=23)
$input_errors[] = gettext("A valid PPPoE reset hour must be specified (0-23).");
@@ -230,15 +230,15 @@ if ($_POST) {
foreach($_POST['interfaces'] as $iface){
if ($_POST['localip'][$iface] && !is_ipaddr($_POST['localip'][$iface]))
- $input_errors[] = "A valid local IP address must be specified for {$iface}.";
+ $input_errors[] = sprintf(gettext("A valid local IP address must be specified for %s."),$iface);
if ($_POST['gateway'][$iface] && !is_ipaddr($_POST['gateway'][$iface]) && !is_hostname($_POST['gateway'][$iface]))
- $input_errors[] = "A valid gateway IP address OR hostname must be specified for {$iface}.";
+ $input_errors[] = sprintf(gettext("A valid gateway IP address OR hostname must be specified for %s."),$iface);
if ($_POST['bandwidth'][$iface] && !is_numericint($_POST['bandwidth'][$iface]))
- $input_errors[] = "The bandwidth value for {$iface} must be an integer.";
+ $input_errors[] = sprintf(gettext("The bandwidth value for %s must be an integer."),$iface);
if ($_POST['mtu'][$iface] && ($_POST['mtu'][$iface] < 576))
- $input_errors[] = "The MTU for {$iface} must be greater than 576 bytes.";
+ $input_errors[] = sprintf(gettext("The MTU for %s must be greater than 576 bytes."),$iface);
if ($_POST['mru'][$iface] && ($_POST['mru'][$iface] < 576))
- $input_errors[] = "The MRU for {$iface} must be greater than 576 bytes.";
+ $input_errors[] = sprintf(gettext("The MRU for %s must be greater than 576 bytes."),$iface);
}
/*
@@ -370,10 +370,10 @@ if ($_POST) {
} // end if($_POST)
$closehead = false;
-$pgtitle = array("Interfaces","PPPs","Edit");
+$pgtitle = array(gettext("Interfaces"),gettext("PPPs"),gettext("Edit"));
include("head.inc");
-$types = array("select" => "Select", "ppp" => "PPP", "pppoe" => "PPPoE", "pptp" => "PPTP", "l2tp" => "L2TP"/*, "tcp" => "TCP", "udp" => "UDP"*/ );
+$types = array("select" => gettext("Select"), "ppp" => "PPP", "pppoe" => "PPPoE", "pptp" => "PPTP", "l2tp" => "L2TP"/*, "tcp" => "TCP", "udp" => "UDP"*/ );
?>
<script type="text/javascript" src="/javascript/numericupdown/js/numericupdown.js"></script>
@@ -558,8 +558,8 @@ $types = array("select" => "Select", "ppp" => "PPP", "pppoe" => "PPPoE", "pptp"
<td width="22%" valign="top" class="vncell"><?= gettext("Init String"); ?></td>
<td width="78%" class="vtable">
<input type="text" size="40" class="formfld unknown" id="initstr" name="initstr" value="<?=htmlspecialchars($pconfig['initstr']);?>">
- <br/><span class="vexpl"><?= gettext("Note: Enter the modem initialization string here. Do NOT include the \"AT\"
- string at the beginning of the command. Many modern USB 3G modems don't need an initialization string."); ?></span>
+ <br/><span class="vexpl"><?= gettext("Note: Enter the modem initialization string here. Do NOT include the \"AT\"" .
+ "string at the beginning of the command. Many modern USB 3G modems don't need an initialization string."); ?></span>
</td>
</tr>
<tr style="display:none" id="advanced_<?=$k;?>" name="advanced_<?=$k;$k++;?>">
@@ -613,7 +613,7 @@ $types = array("select" => "Select", "ppp" => "PPP", "pppoe" => "PPPoE", "pptp"
<input name="pppoe_resetdate" type="text" class="w8em format-m-d-y highlight-days-67" id="pppoe_resetdate" maxlength="10" size="10" value="<?=htmlspecialchars($pconfig['pppoe_resetdate']);?>" />
<?= gettext("reset at a specific date (mm/dd/yyyy)"); ?>
<br />&nbsp;<br />
- <span class="red"><strong>Note: </strong></span>
+ <span class="red"><strong><?=gettext("Note ");?>:</strong></span>
<?= gettext("If you leave the date field empty, the reset will be executed each day at the time you did specify using the minutes and hour field."); ?>
</p>
<?php if ($pconfig['pppoe_pr_preset']): ?>
@@ -674,55 +674,55 @@ $types = array("select" => "Select", "ppp" => "PPP", "pppoe" => "PPPoE", "pptp"
<td valign="top" class="vncell"><?= gettext("Dial On Demand"); ?></td>
<td class="vtable">
<input type="checkbox" value="on" id="ondemand" name="ondemand" <?php if (isset($pconfig['ondemand'])) echo "checked"; ?>> <?= gettext("Enable Dial-on-Demand mode"); ?>
- <br/> <span class="vexpl"><?= gettext("This option causes the interface to operate in dial-on-demand mode, allowing you to have a virtual full time connection.
- The interface is configured, but the actual connection of the link is delayed until qualifying outgoing traffic is detected."); ?> </span>
+ <br/> <span class="vexpl"><?= gettext("This option causes the interface to operate in dial-on-demand mode, allowing you to have a virtual full time connection. " .
+ "The interface is configured, but the actual connection of the link is delayed until qualifying outgoing traffic is detected."); ?> </span>
</td>
</tr>
<tr style="display:none" id="advanced_<?=$k;?>" name="advanced_<?=$k;$k++;?>">
<td valign="top" class="vncell"><?= gettext("Idle Timeout"); ?></td>
<td class="vtable">
<input name="idletimeout" type="text" class="formfld unknown" id="idletimeout" size="12" value="<?=htmlspecialchars($pconfig['idletimeout']);?>"> <?= gettext("(seconds) Default is 0, which disables the timeout feature."); ?>
- <br/> <span class="vexpl"><?= gettext("If no incoming or outgoing packets are transmitted for the entered number of seconds the connection is brought down.
- <br/>When the idle timeout occurs, if the dial-on-demand option is enabled, mpd goes back into dial-on-demand mode. Otherwise, the interface is brought down and all associated routes removed."); ?></span>
+ <br/> <span class="vexpl"><?= gettext("If no incoming or outgoing packets are transmitted for the entered number of seconds the connection is brought down.");?>
+ <br/><?=gettext("When the idle timeout occurs, if the dial-on-demand option is enabled, mpd goes back into dial-on-demand mode. Otherwise, the interface is brought down and all associated routes removed."); ?></span>
</td>
</tr>
<tr style="display:none" id="advanced_<?=$k;?>" name="advanced_<?=$k;$k++;?>">
<td width="22%" valign="top" class="vncell"><?= gettext("Compression"); ?></td>
<td width="78%" class="vtable">
<input type="checkbox" value="on" id="vjcomp" name="vjcomp" <?php if (isset($pconfig['vjcomp'])) echo "checked"; ?>>&nbsp;<?= gettext("Disable vjcomp(compression) (auto-negotiated by default)."); ?>
- <br/> <span class="vexpl">This option enables Van Jacobson TCP header compression, which saves several bytes per TCP data packet.
- You almost always want this option. This compression ineffective for TCP connections with enabled modern extensions like time
- stamping or SACK, which modify TCP options between sequential packets.</span>
+ <br/> <span class="vexpl"><?=gettext("This option enables Van Jacobson TCP header compression, which saves several bytes per TCP data packet. " .
+ "You almost always want this option. This compression ineffective for TCP connections with enabled modern extensions like time " .
+ "stamping or SACK, which modify TCP options between sequential packets.");?></span>
</td>
</tr>
<tr style="display:none" id="advanced_<?=$k;?>" name="advanced_<?=$k;$k++;?>">
<td width="22%" valign="top" class="vncell"><?= gettext("TCPmssFix"); ?></td>
<td width="78%" class="vtable">
<input type="checkbox" value="on" id="tcpmssfix" name="tcpmssfix" <?php if (isset($pconfig['tcpmssfix'])) echo "checked"; ?>>&nbsp;<?= gettext("Disable tcpmssfix (enabled by default)."); ?>
- <br/> <span class="vexpl">This option causes mpd to adjust incoming and outgoing TCP SYN segments so that the requested maximum segment size is not greater than the amount
- allowed by the interface MTU. This is necessary in many setups to avoid problems caused by routers that drop ICMP Datagram Too Big messages. Without these messages,
- the originating machine sends data, it passes the rogue router then hits a machine that has an MTU that is not big enough for the data. Because the IP Don't Fragment option is set,
- this machine sends an ICMP Datagram Too Big message back to the originator and drops the packet. The rogue router drops the ICMP message and the originator never
- gets to discover that it must reduce the fragment size or drop the IP Don't Fragment option from its outgoing data.</span>
+ <br/> <span class="vexpl"><?=gettext("This option causes mpd to adjust incoming and outgoing TCP SYN segments so that the requested maximum segment size is not greater than the amount ".
+ "allowed by the interface MTU. This is necessary in many setups to avoid problems caused by routers that drop ICMP Datagram Too Big messages. Without these messages, ".
+ "the originating machine sends data, it passes the rogue router then hits a machine that has an MTU that is not big enough for the data. Because the IP Don't Fragment option is set, ".
+ "this machine sends an ICMP Datagram Too Big message back to the originator and drops the packet. The rogue router drops the ICMP message and the originator never ".
+ "gets to discover that it must reduce the fragment size or drop the IP Don't Fragment option from its outgoing data.");?></span>
</td>
</tr>
<tr style="display:none" id="advanced_<?=$k;?>" name="advanced_<?=$k;$k++;?>">
- <td width="22%" valign="top" class="vncell">ShortSeq</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("ShortSeq");?></td>
<td width="78%" class="vtable">
<input type="checkbox" value="on" id="shortseq" name="shortseq" <?php if (isset($pconfig['shortseq'])) echo "checked"; ?>>&nbsp;<?= gettext("Disable shortseq (auto-negotiated by default)."); ?>
- <br/> <span class="vexpl"><?= gettext("This option is only meaningful if multi-link PPP is negotiated. It proscribes shorter multi-link fragment headers, saving two bytes on every frame.
- It is not necessary to disable this for connections that are not multi-link."); ?></span>
+ <br/> <span class="vexpl"><?= gettext("This option is only meaningful if multi-link PPP is negotiated. It proscribes shorter multi-link fragment headers, saving two bytes on every frame. " .
+ "It is not necessary to disable this for connections that are not multi-link."); ?></span>
</td>
</tr>
<tr style="display:none" id="advanced_<?=$k;?>" name="advanced_<?=$k;$k++;?>">
- <td width="22%" valign="top" class="vncell">ACFComp</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("ACFComp"); ?></td>
<td width="78%" class="vtable">
<input type="checkbox" value="on" id="acfcomp" name="acfcomp" <?php if (isset($pconfig['acfcomp'])) echo "checked"; ?>>&nbsp;<?= gettext("Disable acfcomp(compression) (auto-negotiated by default)."); ?>
<br/> <span class="vexpl"><?= gettext("Address and control field compression. This option only applies to asynchronous link types. It saves two bytes per frame."); ?></span>
</td>
</tr>
<tr style="display:none" id="advanced_<?=$k;?>" name="advanced_<?=$k;$k++;?>">
- <td width="22%" valign="top" class="vncell">ProtoComp</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("ProtoComp"); ?></td>
<td width="78%" class="vtable">
<input type="checkbox" value="on" id="protocomp" name="protocomp" <?php if (isset($pconfig['protocomp'])) echo "checked"; ?>>&nbsp;<?= gettext("Disable protocomp(compression) (auto-negotiated by default)."); ?>
<br/> <span class="vexpl"><?= gettext("Protocol field compression. This option saves one byte per frame for most frames."); ?></span>
@@ -731,7 +731,7 @@ $types = array("select" => "Select", "ppp" => "PPP", "pppoe" => "PPPoE", "pptp"
<tr id="advanced_" name="advanced_">
<td>&nbsp;</td>
<td>
- <p><input type="button" onClick="show_advanced(1)" value="Show advanced options"></p>
+ <p><input type="button" onClick="show_advanced(1)" value="<?=gettext("Show advanced options"); ?>"></p>
</td>
<td style="display:none" id="adv_rows" name="adv_rows"><?=$k;?></td>
<td style="display:none" id="adv_show" name="adv_show">0</td>
@@ -739,28 +739,28 @@ $types = array("select" => "Select", "ppp" => "PPP", "pppoe" => "PPPoE", "pptp"
<tr>
<?php for($i=0; $i < $port_count; $i++) : ?>
<tr style="display:none" id="link<?=$i;?>">
- <td width="22%" valign="top" id="linklabel<?=$i;?>" class="vncell"> Link Parameters</td>
+ <td width="22%" valign="top" id="linklabel<?=$i;?>" class="vncell"> <?=gettext("Link Parameters");?></td>
<td class="vtable">
<table name="link_parameters" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td width="22%" id="bwlabel<?=$i;?>" valign="top"class="vncell"> Bandwidth</td>
+ <td width="22%" id="bwlabel<?=$i;?>" valign="top"class="vncell"> <?=gettext("Bandwidth");?></td>
<td width="78%" class="vtable">
<br/><input name="bandwidth[]" id="bandwidth<?=$i;?>" type="text" class="formfld unknown" size="40" value="<?=htmlspecialchars($pconfig['bandwidth'][$i]);?>">
- <br/> <span class="vexpl">Set Bandwidth for each link ONLY for MLPPP connections and ONLY when links have different bandwidths.</span>
+ <br/> <span class="vexpl"><?=gettext("Set Bandwidth for each link ONLY for MLPPP connections and ONLY when links have different bandwidths.");?></span>
</td>
</tr>
<tr>
- <td width="22%" id="mtulabel<?=$i;?>" valign="top" class="vncell"> MTU</td>
+ <td width="22%" id="mtulabel<?=$i;?>" valign="top" class="vncell"> <?=gettext("MTU"); ?></td>
<td width="78%" class="vtable">
<input name="mtu[]" id="mtu<?=$i;?>" type="text" class="formfld unknown" size="6" value="<?=htmlspecialchars($pconfig['mtu'][$i]);?>">
- <br> <span class="vexpl">MTU will default to 1492.</span>
+ <br> <span class="vexpl"><?=gettext("MTU will default to 1492.");?></span>
</td>
</tr>
<tr>
- <td width="22%" id="mrulabel<?=$i;?>" valign="top" class="vncell"> MRU</td>
+ <td width="22%" id="mrulabel<?=$i;?>" valign="top" class="vncell"> <?=gettext("MRU"); ?></td>
<td width="78%" class="vtable">
<input name="mru[]" id="mru<?=$i;?>" type="text" class="formfld unknown" size="6" value="<?=htmlspecialchars($pconfig['mru'][$i]);?>">
- <br> <span class="vexpl">MRU will default to 1492.</span>
+ <br> <span class="vexpl"><?=gettext("MRU will default to 1492.");?></span>
</td>
</tr>
</table
@@ -769,8 +769,8 @@ $types = array("select" => "Select", "ppp" => "PPP", "pppoe" => "PPPoE", "pptp"
<tr>
<td width="22%" valign="top">&nbsp;</td>
<td width="78%">
- <input name="Submit" type="submit" class="formbtn" value="Save">
- <input type="button" value="Cancel" onclick="history.back()">
+ <input name="Submit" type="submit" class="formbtn" value="<?=gettext("Save"); ?>">
+ <input type="button" value="<?=gettext("Cancel"); ?>" onclick="history.back()">
<input name="ptpid" type="hidden" value="<?=htmlspecialchars($pconfig['ptpid']);?>">
<?php if (isset($id) && $a_ppps[$id]): ?>
<input name="id" type="hidden" value="<?=$id;?>">
diff --git a/usr/local/www/interfaces_qinq.php b/usr/local/www/interfaces_qinq.php
index f25a5dc..a91d045 100755
--- a/usr/local/www/interfaces_qinq.php
+++ b/usr/local/www/interfaces_qinq.php
@@ -39,6 +39,7 @@
##|-PRIV
require("guiconfig.inc");
+require_once("functions.inc");
if (!is_array($config['qinqs']['qinqentry']))
$config['qinqs']['qinqentry'] = array();
@@ -60,7 +61,7 @@ function qinq_inuse($num) {
if ($_GET['act'] == "del") {
/* check if still in use */
if (qinq_inuse($_GET['id'])) {
- $input_errors[] = "This QinQ cannot be deleted because it is still being used as an interface.";
+ $input_errors[] = gettext("This QinQ cannot be deleted because it is still being used as an interface.");
} else {
$id = $_GET['id'];
$qinq =& $a_qinqs[$id];
@@ -81,7 +82,7 @@ if ($_GET['act'] == "del") {
}
}
-$pgtitle = array("Interfaces","QinQ");
+$pgtitle = array(gettext("Interfaces"),gettext("QinQ"));
include("head.inc");
?>
@@ -93,16 +94,16 @@ include("head.inc");
<tr><td>
<?php
$tab_array = array();
- $tab_array[0] = array("Interface assignments", false, "interfaces_assign.php");
- $tab_array[1] = array("Interface Groups", false, "interfaces_groups.php");
- $tab_array[2] = array("Wireless", false, "interfaces_wireless.php");
- $tab_array[3] = array("VLANs", false, "interfaces_vlan.php");
- $tab_array[4] = array("QinQs", true, "interfaces_qinq.php");
- $tab_array[5] = array("PPPs", false, "interfaces_ppps.php");
- $tab_array[6] = array("GRE", false, "interfaces_gre.php");
- $tab_array[7] = array("GIF", false, "interfaces_gif.php");
- $tab_array[8] = array("Bridges", false, "interfaces_bridge.php");
- $tab_array[9] = array("LAGG", false, "interfaces_lagg.php");
+ $tab_array[0] = array(gettext("Interface assignments"), false, "interfaces_assign.php");
+ $tab_array[1] = array(gettext("Interface Groups"), false, "interfaces_groups.php");
+ $tab_array[2] = array(gettext("Wireless"), false, "interfaces_wireless.php");
+ $tab_array[3] = array(gettext("VLANs"), false, "interfaces_vlan.php");
+ $tab_array[4] = array(gettext("QinQs"), true, "interfaces_qinq.php");
+ $tab_array[5] = array(gettext("PPPs"), false, "interfaces_ppps.php");
+ $tab_array[6] = array(gettext("GRE"), false, "interfaces_gre.php");
+ $tab_array[7] = array(gettext("GIF"), false, "interfaces_gif.php");
+ $tab_array[8] = array(gettext("Bridges"), false, "interfaces_bridge.php");
+ $tab_array[9] = array(gettext("LAGG"), false, "interfaces_lagg.php");
display_top_tabs($tab_array);
?>
</td></tr>
@@ -111,10 +112,10 @@ include("head.inc");
<div id="mainarea">
<table class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
- <td width="15%" class="listhdrr">Interface</td>
- <td width="10%" class="listhdrr">Tag</td>
- <td width="20%" class="listhdrr">QinQ members</td>
- <td width="45%" class="listhdr">Description</td>
+ <td width="15%" class="listhdrr"><?=gettext("Interface");?></td>
+ <td width="10%" class="listhdrr"><?=gettext("Tag");?></td>
+ <td width="20%" class="listhdrr"><?=gettext("QinQ members");?></td>
+ <td width="45%" class="listhdr"><?=gettext("Description");?></td>
<td width="10%" class="list"></td>
</tr>
<?php $i = 0; foreach ($a_qinqs as $qinq): ?>
@@ -137,7 +138,7 @@ include("head.inc");
<?=htmlspecialchars($qinq['descr']);?>&nbsp;
</td>
<td valign="middle" nowrap class="list"> <a href="interfaces_qinq_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a>
- &nbsp;<a href="interfaces_qinq.php?act=del&id=<?=$i;?>" onclick="return confirm('Do you really want to delete this QinQ?')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
+ &nbsp;<a href="interfaces_qinq.php?act=del&id=<?=$i;?>" onclick="return confirm('<?=gettext("Do you really want to delete this QinQ?");?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
</tr>
<?php $i++; endforeach; ?>
<tr>
@@ -146,9 +147,9 @@ include("head.inc");
</tr>
<tr>
<td colspan="3" class="list"><p class="vexpl"><span class="red"><strong>
- Note:<br>
+ <?=gettext("Note");?>:<br>
</strong></span>
- Not all drivers/NICs support 802.1Q QinQ tagging properly. On cards that do not explicitly support it, QinQ tagging will still work, but the reduced MTU may cause problems. See the <?=$g['product_name']?> handbook for information on supported cards. </p>
+ <?php printf(gettext("Not all drivers/NICs support 802.1Q QinQ tagging properly. On cards that do not explicitly support it, QinQ tagging will still work, but the reduced MTU may cause problems. See the %s handbook for information on supported cards."), $g['product_name']);?></p>
</td>
<td class="list">&nbsp;</td>
</tr>
diff --git a/usr/local/www/interfaces_qinq_edit.php b/usr/local/www/interfaces_qinq_edit.php
index 1ea76e4..a820e14 100755
--- a/usr/local/www/interfaces_qinq_edit.php
+++ b/usr/local/www/interfaces_qinq_edit.php
@@ -36,7 +36,7 @@
##|*MATCH=interfaces_qinq_edit.php*
##|-PRIV
-$pgtitle = array("Interfaces","QinQ", "Edit");
+$pgtitle = array(gettext("Interfaces"),gettext("QinQ"), gettext("Edit"));
require("guiconfig.inc");
@@ -81,19 +81,19 @@ if ($_POST) {
$pconfig = $_POST;
if (empty($_POST['tag']))
- $input_errors[] = "First level tag cannot be empty.";
+ $input_errors[] = gettext("First level tag cannot be empty.");
if (isset($id) && $a_qinqs[$id]['tag'] != $_POST['tag'])
- $input_errors[] = "You are editing an existing entry and modifying the first level tag is not allowed.";
+ $input_errors[] = gettext("You are editing an existing entry and modifying the first level tag is not allowed.");
if (isset($id) && $a_qinqs[$id]['if'] != $_POST['if'])
- $input_errors[] = "You are editing an existing entry and modifying the interface is not allowed.";
+ $input_errors[] = gettext("You are editing an existing entry and modifying the interface is not allowed.");
if (!isset($id)) {
foreach ($a_qinqs as $qinqentry)
if ($qinqentry['tag'] == $_POST['tag'] && $qinqentry['if'] == $_POST['if'])
- $input_errors[] = "QinQ level already exists for this interface, edit it!";
+ $input_errors[] = gettext("QinQ level already exists for this interface, edit it!");
if (is_array($config['vlans']['vlan'])) {
foreach ($config['vlans']['vlan'] as $vlan)
if ($vlan['tag'] == $_POST['tag'] && $vlan['if'] == $_POST['if'])
- $input_errors[] = "A normal VLAN exists with this tag please remove it to use this tag for QinQ first level.";
+ $input_errors[] = gettext("A normal VLAN exists with this tag please remove it to use this tag for QinQ first level.");
}
}
@@ -120,7 +120,7 @@ if ($_POST) {
if (count($member) > 1) {
if (preg_match("/([^0-9])+/", $member[0], $match) ||
preg_match("/([^0-9])+/", $member[1], $match))
- $input_errors[] = "Tags can contain only numbers or a range in format #-#.";
+ $input_errors[] = gettext("Tags can contain only numbers or a range in format #-#.");
for ($i = $member[0]; $i <= $member[1]; $i++) {
if ($isfirst > 0)
@@ -130,7 +130,7 @@ if ($_POST) {
}
} else {
if (preg_match("/([^0-9])+/", $_POST["members{$x}"], $match))
- $input_errors[] = "Tags can contain only numbers or a range in format #-#.";
+ $input_errors[] = gettext("Tags can contain only numbers or a range in format #-#.");
if ($isfirst > 0)
$members .= " ";
@@ -190,7 +190,7 @@ if ($_POST) {
$gentry = array();
$gentry['ifname'] = "QinQ";
$gentry['members'] = "{$additions}";
- $gentry['descr'] = "QinQ VLANs group";
+ $gentry['descr'] = gettext("QinQ VLANs group");
$config['ifgroups']['ifgroupentry'][] = $gentry;
}
}
@@ -266,11 +266,11 @@ function removeRow(el) {
}
}
- rowname[0] = "members";
+ rowname[0] = <?=gettext("members");?>;
rowtype[0] = "textbox";
rowsize[0] = "30";
- rowname[2] = "detail";
+ rowname[2] = <?=gettext("detail");?>;
rowtype[2] = "textbox";
rowsize[2] = "50";
</script>
@@ -282,10 +282,10 @@ function removeRow(el) {
<form action="interfaces_qinq_edit.php" method="post" name="iform" id="iform">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">Interface QinQ Edit</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("Interface QinQ Edit");?></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">Parent interface</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Parent interface");?></td>
<td width="78%" class="vtable">
<select name="if" id="if" class="formselect">
<?php
@@ -302,20 +302,20 @@ function removeRow(el) {
?>
</select>
<br/>
- <span class="vexpl">Only QinQ capable interfaces will be shown.</span></td>
+ <span class="vexpl"><?=gettext("Only QinQ capable interfaces will be shown.");?></span></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">First level tag</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("First level tag");?></td>
<td width="78%" class="vtable">
<input name="tag" type="text" class="formfld unknown" id="tag" size="10" value="<?=$pconfig['tag'];?>" />
<br />
<span class="vexpl">
- This is the first level VLAN tag. On top of this are stacked the member VLANs defined below.
+ <?=gettext("This is the first level VLAN tag. On top of this are stacked the member VLANs defined below.");?>
</span>
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Options</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Options");?></td>
<td width="78%" class="vtable">
<?php /* ?>
<br/>
@@ -330,30 +330,30 @@ function removeRow(el) {
<?php */ ?>
<br/>
<input name="autogroup" type="checkbox" value="yes" id="autogroup" <? if ($pconfig['autogroup']) echo "checked";?>>
- <span class="vexpl"> Adds interface to QinQ interface groups so you can write filter rules easily.</span>
+ <span class="vexpl"><?=gettext("Adds interface to QinQ interface groups so you can write filter rules easily.");?></span>
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Description</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Description");?></td>
<td width="78%" class="vtable">
<input name="descr" type="text" class="formfld unknown" id="descr" size="40" value="<?=$pconfig['descr'];?>" />
<br />
<span class="vexpl">
- You may enter a description here for your reference (not parsed).
+ <?=gettext("You may enter a description here for your reference (not parsed).");?>
</span>
</td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq"><div id="membersnetworkport">Member (s)</div></td>
+ <td width="22%" valign="top" class="vncellreq"><div id="membersnetworkport"><?=gettext("Member (s)");?></div></td>
<td width="78%" class="vtable">
<span vlass="vexpl">
- You can specify ranges in the input below. The format is pretty simple i.e 9-100 or 10.20...
+ <?=gettext("You can specify ranges in the input below. The format is pretty simple i.e 9-100 or 10.20...");?>
</span>
<br/>
<table id="maintable">
<tbody>
<tr>
- <td><div id="onecolumn">Tag</div></td>
+ <td><div id="onecolumn"><?=gettext("Tag");?></div></td>
</tr>
<?php
@@ -370,7 +370,7 @@ function removeRow(el) {
<input name="members<?php echo $tracker; ?>" class="formselect" id="members<?php echo $tracker; ?>" value="<? echo $members;?>">
</td>
<td>
- <input type="image" src="/themes/<?echo $g['theme'];?>/images/icons/icon_x.gif" onclick="removeRow(this); return false;" value="Delete" />
+ <input type="image" src="/themes/<?echo $g['theme'];?>/images/icons/icon_x.gif" onclick="removeRow(this); return false;" value="<?=gettext("Delete");?>" />
</td>
</tr>
<?php
@@ -385,15 +385,15 @@ function removeRow(el) {
</tfoot>
</table>
<a onclick="javascript:addRowTo('maintable'); return false;" href="#">
- <img border="0" src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" alt="" title="add another entry" />
+ <img border="0" src="/themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" alt="" title="<?=gettext("add another entry");?>" />
</a>
</td>
</tr>
<tr>
<td width="22%" valign="top">&nbsp;</td>
<td width="78%">
- <input id="submit" name="submit" type="submit" class="formbtn" value="Save" />
- <a href="interfaces_qinq.php"><input id="cancelbutton" name="cancelbutton" type="button" class="formbtn" value="Cancel" /></a>
+ <input id="submit" name="submit" type="submit" class="formbtn" value="<?=gettext("Save");?>" />
+ <a href="interfaces_qinq.php"><input id="cancelbutton" name="cancelbutton" type="button" class="formbtn" value="<?=gettext("Cancel");?>" /></a>
<?php if (isset($id) && $a_qinqs[$id]): ?>
<input name="id" type="hidden" value="<?=$id;?>" />
<?php endif; ?>
diff --git a/usr/local/www/interfaces_vlan.php b/usr/local/www/interfaces_vlan.php
index cd8975c..1206d20 100755
--- a/usr/local/www/interfaces_vlan.php
+++ b/usr/local/www/interfaces_vlan.php
@@ -62,7 +62,7 @@ function vlan_inuse($num) {
if ($_GET['act'] == "del") {
/* check if still in use */
if (vlan_inuse($_GET['id'])) {
- $input_errors[] = "This VLAN cannot be deleted because it is still being used as an interface.";
+ $input_errors[] = gettext("This VLAN cannot be deleted because it is still being used as an interface.");
} else {
mwexec("/sbin/ifconfig " . $a_vlans[$_GET['id']]['vlanif'] . " destroy");
unset($a_vlans[$_GET['id']]);
@@ -75,7 +75,7 @@ if ($_GET['act'] == "del") {
}
-$pgtitle = array("Interfaces","VLAN");
+$pgtitle = array(gettext("Interfaces"),gettext("VLAN"));
include("head.inc");
?>
@@ -87,16 +87,16 @@ include("head.inc");
<tr><td>
<?php
$tab_array = array();
- $tab_array[0] = array("Interface assignments", false, "interfaces_assign.php");
- $tab_array[1] = array("Interface Groups", false, "interfaces_groups.php");
- $tab_array[2] = array("Wireless", false, "interfaces_wireless.php");
- $tab_array[3] = array("VLANs", true, "interfaces_vlan.php");
- $tab_array[4] = array("QinQs", false, "interfaces_qinq.php");
- $tab_array[5] = array("PPPs", false, "interfaces_ppps.php");
- $tab_array[6] = array("GRE", false, "interfaces_gre.php");
- $tab_array[7] = array("GIF", false, "interfaces_gif.php");
- $tab_array[8] = array("Bridges", false, "interfaces_bridge.php");
- $tab_array[9] = array("LAGG", false, "interfaces_lagg.php");
+ $tab_array[0] = array(gettext("Interface assignments"), false, "interfaces_assign.php");
+ $tab_array[1] = array(gettext("Interface Groups"), false, "interfaces_groups.php");
+ $tab_array[2] = array(gettext("Wireless"), false, "interfaces_wireless.php");
+ $tab_array[3] = array(gettext("VLANs"), true, "interfaces_vlan.php");
+ $tab_array[4] = array(gettext("QinQs"), false, "interfaces_qinq.php");
+ $tab_array[5] = array(gettext("PPPs"), false, "interfaces_ppps.php");
+ $tab_array[6] = array(gettext("GRE"), false, "interfaces_gre.php");
+ $tab_array[7] = array(gettext("GIF"), false, "interfaces_gif.php");
+ $tab_array[8] = array(gettext("Bridges"), false, "interfaces_bridge.php");
+ $tab_array[9] = array(gettext("LAGG"), false, "interfaces_lagg.php");
display_top_tabs($tab_array);
?>
</td></tr>
@@ -105,9 +105,9 @@ include("head.inc");
<div id="mainarea">
<table class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
- <td width="20%" class="listhdrr">Interface</td>
- <td width="20%" class="listhdrr">VLAN tag</td>
- <td width="50%" class="listhdr">Description</td>
+ <td width="20%" class="listhdrr"><?=gettext("Interface");?></td>
+ <td width="20%" class="listhdrr"><?=gettext("VLAN tag");?></td>
+ <td width="50%" class="listhdr"><?=gettext("Description");?></td>
<td width="10%" class="list"></td>
</tr>
<?php $i = 0; foreach ($a_vlans as $vlan): ?>
@@ -122,18 +122,18 @@ include("head.inc");
<?=htmlspecialchars($vlan['descr']);?>&nbsp;
</td>
<td valign="middle" nowrap class="list"> <a href="interfaces_vlan_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a>
- &nbsp;<a href="interfaces_vlan.php?act=del&id=<?=$i;?>" onclick="return confirm('Do you really want to delete this VLAN?')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
+ &nbsp;<a href="interfaces_vlan.php?act=del&id=<?=$i;?>" onclick="return confirm('<?=gettext("Do you really want to delete this VLAN?");?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
</tr>
<?php $i++; endforeach; ?>
<tr>
<td class="list" colspan="3">&nbsp;</td>
- <td class="list"> <a href="interfaces_vlan_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="17" border="0"></a></td>
+ <td class="list"> <a href="interfaces_vlan_edit.php"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_plus.gif" width="17" height="<F12>17" border="0"></a></td>
</tr>
<tr>
<td colspan="3" class="list"><p class="vexpl"><span class="red"><strong>
- Note:<br>
+ <?=gettext("Note");?>:<br>
</strong></span>
- Not all drivers/NICs support 802.1Q VLAN tagging properly. On cards that do not explicitly support it, VLAN tagging will still work, but the reduced MTU may cause problems. See the <?=$g['product_name']?> handbook for information on supported cards. </p>
+ <?php printf(gettext("Not all drivers/NICs support 802.1Q VLAN tagging properly. On cards that do not explicitly support it, VLAN tagging will still work, but the reduced MTU may cause problems. See the %s handbook for information on supported cards."),$g['product_name']);?> </p>
</td>
<td class="list">&nbsp;</td>
</tr>
diff --git a/usr/local/www/interfaces_vlan_edit.php b/usr/local/www/interfaces_vlan_edit.php
index db676f7..3f26441 100755
--- a/usr/local/www/interfaces_vlan_edit.php
+++ b/usr/local/www/interfaces_vlan_edit.php
@@ -72,12 +72,12 @@ if ($_POST) {
/* input validation */
$reqdfields = explode(" ", "if tag");
- $reqdfieldsn = explode(",", "Parent interface,VLAN tag");
+ $reqdfieldsn = array(gettext("Parent interface"),gettext("VLAN tag"));
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
if ($_POST['tag'] && (!is_numericint($_POST['tag']) || ($_POST['tag'] < '1') || ($_POST['tag'] > '4094'))) {
- $input_errors[] = "The VLAN tag must be an integer between 1 and 4094.";
+ $input_errors[] = gettext("The VLAN tag must be an integer between 1 and 4094.");
}
foreach ($a_vlans as $vlan) {
@@ -85,14 +85,14 @@ if ($_POST) {
continue;
if (($vlan['if'] == $_POST['if']) && ($vlan['tag'] == $_POST['tag'])) {
- $input_errors[] = "A VLAN with the tag {$vlan['tag']} is already defined on this interface.";
+ $input_errors[] = sprintf(gettext("A VLAN with the tag %s is already defined on this interface."),$vlan['tag']);
break;
}
}
if (is_array($config['qinqs']['qinqentry'])) {
foreach ($config['qinqs']['qinqentry'] as $qinq)
if ($qinq['tag'] == $_POST['tag'] && $qinq['if'] == $_POST['if'])
- $input_errors[] = "A QinQ VLAN exists with this tag please remove it to use this tag with.";
+ $input_errors[] = gettext("A QinQ VLAN exists with this tag please remove it to use this tag with.");
}
if (!$input_errors) {
@@ -104,7 +104,7 @@ if ($_POST) {
$vlan['vlanif'] = interface_vlan_configure($vlan);
if ($vlan['vlanif'] == "" || !stristr($vlan['vlanif'], "vlan"))
- $input_errors[] = "Error occured creating interface, please retry.";
+ $input_errors[] = gettext("Error occured creating interface, please retry.");
else {
if (isset($id) && $a_vlans[$id])
$a_vlans[$id] = $vlan;
@@ -123,7 +123,7 @@ if ($_POST) {
}
}
-$pgtitle = array("Firewall","VLAN","Edit");
+$pgtitle = array(gettext("Firewall"),gettext("VLAN"),gettext("Edit"));
include("head.inc");
?>
@@ -134,10 +134,10 @@ include("head.inc");
<form action="interfaces_vlan_edit.php" method="post" name="iform" id="iform">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">VLAN configuration</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("VLAN configuration");?></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">Parent interface</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Parent interface");?></td>
<td width="78%" class="vtable">
<select name="if" class="formselect">
<?php
@@ -153,27 +153,27 @@ include("head.inc");
?>
</select>
<br/>
- <span class="vexpl">Only VLAN capable interfaces will be shown.</span></td>
+ <span class="vexpl"><?=gettext("Only VLAN capable interfaces will be shown.");?></span></td>
</tr>
<tr>
- <td valign="top" class="vncellreq">VLAN tag </td>
+ <td valign="top" class="vncellreq"><?=gettext("VLAN tag ");?></td>
<td class="vtable">
<input name="tag" type="text" class="formfld unknown" id="tag" size="6" value="<?=htmlspecialchars($pconfig['tag']);?>">
<br>
- <span class="vexpl">802.1Q VLAN tag (between 1 and 4094) </span></td>
+ <span class="vexpl"><?=gettext("802.1Q VLAN tag (between 1 and 4094) ");?></span></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Description</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Description");?></td>
<td width="78%" class="vtable">
<input name="descr" type="text" class="formfld unknown" id="descr" size="40" value="<?=htmlspecialchars($pconfig['descr']);?>">
- <br> <span class="vexpl">You may enter a description here
- for your reference (not parsed).</span></td>
+ <br> <span class="vexpl"><?=gettext("You may enter a description here ".
+ "for your reference (not parsed).");?></span></td>
</tr>
<tr>
<td width="22%" valign="top">&nbsp;</td>
<td width="78%">
<input type="hidden" name="vlanif" value="<?=$pconfig['vlanif']; ?>">
- <input name="Submit" type="submit" class="formbtn" value="Save"> <input type="button" value="Cancel" onclick="history.back()">
+ <input name="Submit" type="submit" class="formbtn" value="<?=gettext("Save");?>"> <input type="button" value="<?=gettext("Cancel");?>" onclick="history.back()">
<?php if (isset($id) && $a_vlans[$id]): ?>
<input name="id" type="hidden" value="<?=$id;?>">
<?php endif; ?>
diff --git a/usr/local/www/interfaces_wireless.php b/usr/local/www/interfaces_wireless.php
index 42fd149..3e1c755 100644
--- a/usr/local/www/interfaces_wireless.php
+++ b/usr/local/www/interfaces_wireless.php
@@ -60,7 +60,7 @@ function clone_inuse($num) {
if ($_GET['act'] == "del") {
/* check if still in use */
if (clone_inuse($_GET['id'])) {
- $input_errors[] = "This wireless clone cannot be deleted because it is assigned as an interface.";
+ $input_errors[] = gettext("This wireless clone cannot be deleted because it is assigned as an interface.");
} else {
mwexec("/sbin/ifconfig " . $a_clones[$_GET['id']]['cloneif'] . " destroy");
unset($a_clones[$_GET['id']]);
@@ -73,7 +73,7 @@ if ($_GET['act'] == "del") {
}
-$pgtitle = array("Interfaces","Wireless");
+$pgtitle = array(gettext("Interfaces"),gettext("Wireless"));
include("head.inc");
?>
@@ -85,16 +85,16 @@ include("head.inc");
<tr><td>
<?php
$tab_array = array();
- $tab_array[0] = array("Interface assignments", false, "interfaces_assign.php");
- $tab_array[1] = array("Interface Groups", false, "interfaces_groups.php");
- $tab_array[2] = array("Wireless", true, "interfaces_wireless.php");
- $tab_array[3] = array("VLANs", false, "interfaces_vlan.php");
- $tab_array[4] = array("QinQs", false, "interfaces_qinq.php");
- $tab_array[5] = array("PPPs", false, "interfaces_ppps.php");
- $tab_array[6] = array("GRE", false, "interfaces_gre.php");
- $tab_array[7] = array("GIF", false, "interfaces_gif.php");
- $tab_array[8] = array("Bridges", false, "interfaces_bridge.php");
- $tab_array[9] = array("LAGG", false, "interfaces_lagg.php");
+ $tab_array[0] = array(gettext("Interface assignments"), false, "interfaces_assign.php");
+ $tab_array[1] = array(gettext("Interface Groups"), false, "interfaces_groups.php");
+ $tab_array[2] = array(gettext("Wireless"), true, "interfaces_wireless.php");
+ $tab_array[3] = array(gettext("VLANs"), false, "interfaces_vlan.php");
+ $tab_array[4] = array(gettext("QinQs"), false, "interfaces_qinq.php");
+ $tab_array[5] = array(gettext("PPPs"), false, "interfaces_ppps.php");
+ $tab_array[6] = array(gettext("GRE"), false, "interfaces_gre.php");
+ $tab_array[7] = array(gettext("GIF"), false, "interfaces_gif.php");
+ $tab_array[8] = array(gettext("Bridges"), false, "interfaces_bridge.php");
+ $tab_array[9] = array(gettext("LAGG"), false, "interfaces_lagg.php");
display_top_tabs($tab_array);
?>
</td></tr>
@@ -103,9 +103,9 @@ include("head.inc");
<div id="mainarea">
<table class="tabcont" width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
- <td width="20%" class="listhdrr">Interface</td>
- <td width="20%" class="listhdrr">Mode</td>
- <td width="50%" class="listhdr">Description</td>
+ <td width="20%" class="listhdrr"><?=gettext("Interface");?></td>
+ <td width="20%" class="listhdrr"><?=gettext("Mode");?></td>
+ <td width="50%" class="listhdr"><?=gettext("Description");?></td>
<td width="10%" class="list"></td>
</tr>
<?php $i = 0;
@@ -121,7 +121,7 @@ include("head.inc");
<?=htmlspecialchars($clone['descr']);?>&nbsp;
</td>
<td valign="middle" nowrap class="list"> <a href="interfaces_wireless_edit.php?id=<?=$i;?>"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_e.gif" width="17" height="17" border="0"></a>
- &nbsp;<a href="interfaces_wireless.php?act=del&id=<?=$i;?>" onclick="return confirm('Do you really want to delete this wireless clone?')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
+ &nbsp;<a href="interfaces_wireless.php?act=del&id=<?=$i;?>" onclick="return confirm('<?=gettext("Do you really want to delete this wireless clone?");?>')"><img src="./themes/<?= $g['theme']; ?>/images/icons/icon_x.gif" width="17" height="17" border="0"></a></td>
</tr>
<?php $i++; endforeach; ?>
<tr>
@@ -130,9 +130,9 @@ include("head.inc");
</tr>
<tr>
<td colspan="3" class="list"><p class="vexpl"><span class="red"><strong>
- Note:<br>
+ <?=gettext("Note");?>:<br>
</strong></span>
- Here you can configure clones of wireless interfaces, which can be assigned as separate independent interfaces. Only available on wireless chipsets that support this, with limitations on the number that can be created in each mode.
+ <?=gettext("Here you can configure clones of wireless interfaces, which can be assigned as separate independent interfaces. Only available on wireless chipsets that support this, with limitations on the number that can be created in each mode.");?>
</td>
<td class="list">&nbsp;</td>
</tr>
diff --git a/usr/local/www/interfaces_wireless_edit.php b/usr/local/www/interfaces_wireless_edit.php
index 1e9419e..4108413 100644
--- a/usr/local/www/interfaces_wireless_edit.php
+++ b/usr/local/www/interfaces_wireless_edit.php
@@ -81,7 +81,7 @@ if ($_POST) {
/* input validation */
$reqdfields = explode(" ", "if mode");
- $reqdfieldsn = explode(",", "Parent interface,Mode");
+ $reqdfieldsn = array(gettext("Parent interface"),gettext("Mode"));
do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors);
@@ -113,22 +113,22 @@ if ($_POST) {
if (isset($id) && $a_clones[$id]) {
if (clone_inuse($id)) {
if ($clone['if'] != $a_clones[$id]['if'])
- $input_errors[] = "This wireless clone cannot be modified because it is still assigned as an interface.";
+ $input_errors[] = gettext("This wireless clone cannot be modified because it is still assigned as an interface.");
else if ($clone['mode'] != $a_clones[$id]['mode'])
- $input_errors[] = "Use the configuration page for the assigned interface to change the mode.";
+ $input_errors[] = gettext("Use the configuration page for the assigned interface to change the mode.");
}
}
if (!$input_errors) {
if (!interface_wireless_clone($clone['cloneif'], $clone)) {
- $input_errors[] = "Error creating interface with mode {$wlan_modes[$clone['mode']]}. The {$clone['if']} interface may not support creating more clones with the selected mode.";
+ $input_errors[] = sprintf(gettext("Error creating interface with mode %s. The %s interface may not support creating more clones with the selected mode."), $wlan_modes[$clone['mode']], $clone['if']);
} else {
if (isset($id) && $a_clones[$id]) {
if ($clone['if'] != $a_clones[$id]['if'])
mwexec("/sbin/ifconfig " . $a_clones[$id]['cloneif'] . " destroy");
- $input_errors[] = "Created with id {$id}";
+ $input_errors[] = sprintf(gettext("Created with id %s"), $id);
$a_clones[$id] = $clone;
} else {
- $input_errors[] = "Created without id";
+ $input_errors[] = gettext("Created without id");
$a_clones[] = $clone;
}
@@ -142,7 +142,7 @@ if ($_POST) {
}
}
-$pgtitle = array("Firewall","Wireless","Edit");
+$pgtitle = array(gettext("Firewall"),gettext("Wireless"),gettext("Edit"));
include("head.inc");
?>
@@ -153,10 +153,10 @@ include("head.inc");
<form action="interfaces_wireless_edit.php" method="post" name="iform" id="iform">
<table width="100%" border="0" cellpadding="6" cellspacing="0">
<tr>
- <td colspan="2" valign="top" class="listtopic">Wireless clone configuration</td>
+ <td colspan="2" valign="top" class="listtopic"><?=gettext("Wireless clone configuration");?></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncellreq">Parent interface</td>
+ <td width="22%" valign="top" class="vncellreq"><?=gettext("Parent interface");?></td>
<td width="78%" class="vtable">
<select name="if" class="formselect">
<?php
@@ -173,26 +173,26 @@ include("head.inc");
</select></td>
</tr>
<tr>
- <td valign="top" class="vncellreq">Mode</td>
+ <td valign="top" class="vncellreq"><?=gettext("Mode");?></td>
<td class="vtable">
<select name="mode" class="formselect">
- <option <? if ($pconfig['mode'] == 'bss') echo "selected";?> value="bss">Infrastructure (BSS)</option>
- <option <? if ($pconfig['mode'] == 'adhoc') echo "selected";?> value="adhoc">Ad-hoc (IBSS)</option>
- <option <? if ($pconfig['mode'] == 'hostap') echo "selected";?> value="hostap">Access Point</option>
+ <option <? if ($pconfig['mode'] == 'bss') echo "selected";?> value="bss"><?=gettext("Infrastructure (BSS)");?></option>
+ <option <? if ($pconfig['mode'] == 'adhoc') echo "selected";?> value="adhoc"><?=gettext("Ad-hoc (IBSS)");?></option>
+ <option <? if ($pconfig['mode'] == 'hostap') echo "selected";?> value="hostap"><?=gettext("Access Point");?></option>
</select></td>
</tr>
<tr>
- <td width="22%" valign="top" class="vncell">Description</td>
+ <td width="22%" valign="top" class="vncell"><?=gettext("Description");?></td>
<td width="78%" class="vtable">
<input name="descr" type="text" class="formfld unknown" id="descr" size="40" value="<?=htmlspecialchars($pconfig['descr']);?>">
- <br> <span class="vexpl">You may enter a description here
- for your reference (not parsed).</span></td>
+ <br> <span class="vexpl"><?=gettext("You may enter a description here ".
+ "for your reference (not parsed).");?></span></td>
</tr>
<tr>
<td width="22%" valign="top">&nbsp;</td>
<td width="78%">
<input type="hidden" name="cloneif" value="<?=$pconfig['cloneif']; ?>">
- <input name="Submit" type="submit" class="formbtn" value="Save"> <input type="button" value="Cancel" onclick="history.back()">
+ <input name="Submit" type="submit" class="formbtn" value="<?=gettext("Save");?>"> <input type="button" value="<?=gettext("Cancel");?>" onclick="history.back()">
<?php if (isset($id) && $a_clones[$id]): ?>
<input name="id" type="hidden" value="<?=$id;?>">
<?php endif; ?>
diff --git a/usr/local/www/status.php b/usr/local/www/status.php
index d1985e3..f01b5bf 100755
--- a/usr/local/www/status.php
+++ b/usr/local/www/status.php
@@ -107,7 +107,7 @@ function defCmd($command) {
/* List all of the commands as an index. */
function listCmds() {
global $commands;
- echo "<p>This status page includes the following information:\n";
+ echo "<p>" . gettext("This status page includes the following information") . ":\n";
echo "<ul width=\"700\">\n";
for ($i = 0; isset($commands[$i]); $i++ ) {
echo "<li><strong><a href=\"#" . $commands[$i][0] . "\">" . $commands[$i][0] . "</a></strong>\n";
@@ -222,10 +222,10 @@ pre {
<body link="#0000CC" vlink="#0000CC" alink="#0000CC">
<?php include("fbegin.inc"); ?>
<strong><?=$currentDate;?></strong>
-<p><span class="red"><strong>Note: make sure to remove any sensitive information
-(passwords, maybe also IP addresses) before posting
-information from this page in public places (like mailing lists)!</strong></span><br>
-Passwords in config.xml have been automatically removed.
+<p><span class="red"><strong><?=gettext("Note: make sure to remove any sensitive information " .
+"(passwords, maybe also IP addresses) before posting " .
+"information from this page in public places (like mailing lists)"); ?>!</strong></span><br>
+<?=gettext("Passwords in config.xml have been automatically removed"); ?>.
<div id="cmdspace" style="width:700px">
<?php listCmds(); ?>
OpenPOWER on IntegriCloud