summaryrefslogtreecommitdiffstats
path: root/usr/local/www/interfaces.php
diff options
context:
space:
mode:
authorgroo <ericitaquera@gmail.com>2010-06-30 18:00:14 -0300
committergroo <ericitaquera@gmail.com>2010-06-30 18:00:59 -0300
commit8cc6876f823744433e3c8200ae2259d97227a0a3 (patch)
tree7bbf80277b8e1dc0433346555ee1f98ef6af8623 /usr/local/www/interfaces.php
parentcbdc84eaf81245fc1691893cf8f33876a8e81831 (diff)
downloadpfsense-8cc6876f823744433e3c8200ae2259d97227a0a3.zip
pfsense-8cc6876f823744433e3c8200ae2259d97227a0a3.tar.gz
Implement gettext() calls on interfaces.php and interfaces_assign.php
Diffstat (limited to 'usr/local/www/interfaces.php')
-rwxr-xr-xusr/local/www/interfaces.php30
1 files changed, 15 insertions, 15 deletions
diff --git a/usr/local/www/interfaces.php b/usr/local/www/interfaces.php
index 4d6283b..9ed372b 100755
--- a/usr/local/www/interfaces.php
+++ b/usr/local/www/interfaces.php
@@ -177,7 +177,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']);
}
}
}
@@ -355,31 +355,31 @@ if ($_POST) {
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;
@@ -433,7 +433,7 @@ if ($_POST) {
/* 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 */
@@ -803,7 +803,7 @@ function check_wireless_mode() {
}
}
-$pgtitle = array("Interfaces", $pconfig['descr']);
+$pgtitle = array(gettext("Interfaces"),sprintf(gettext("'%s'"),$pconfig['descr']));
$statusurl = "status_interfaces.php";
$closehead = false;
@@ -973,7 +973,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">
@@ -998,7 +998,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<td width="22%" valign="top" class="vncell">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>
@@ -1311,7 +1311,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<tr>
<td width="22%" valign="top" class="vncell">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>
@@ -1353,7 +1353,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<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']): ?>
@@ -1823,7 +1823,7 @@ $types = array("none" => "None", "static" => "Static", "dhcp" => "DHCP", "ppp" =
<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/><span class="red"><strong><?= gettext("NOTE"); ?>:</strong</span> this option requires checking the "Enable WPA box".
</td>
</tr>
<tr>
@@ -1888,7 +1888,7 @@ $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="save" name="Submit" type="submit" class="formbtn" value="<?= gettext("Save"); ?>">
<input id="cancel" type="button" class="formbtn" value="Cancel" onclick="history.back()">
<input name="if" type="hidden" id="if" value="<?=$if;?>">
<?php if ($wancfg['if'] == $a_ppps[$pppid]['if']) : ?>
OpenPOWER on IntegriCloud