Commit 66c3b485 authored by Franco Fichtner's avatar Franco Fichtner

src: strip excessive name placement

(cherry picked from commit 6a6f7f3b)
parent 5878e6c7
...@@ -76,8 +76,9 @@ function get_vip_config_section() ...@@ -76,8 +76,9 @@ function get_vip_config_section()
* @param string $method xmlrpc method to call * @param string $method xmlrpc method to call
* @return boolean * @return boolean
*/ */
function carp_check_version($url, $username, $password, $method = 'opnsense.firmware_version') { function carp_check_version($url, $username, $password, $method = 'opnsense.firmware_version')
global $config, $g; {
global $config;
$client = new SimpleXMLRPC_Client($url,240); $client = new SimpleXMLRPC_Client($url,240);
$client->setCredentials($username, $password); $client->setCredentials($username, $password);
...@@ -102,8 +103,8 @@ function carp_check_version($url, $username, $password, $method = 'opnsense.firm ...@@ -102,8 +103,8 @@ function carp_check_version($url, $username, $password, $method = 'opnsense.firm
if (!isset($remote_version['config_version']) || if (!isset($remote_version['config_version']) ||
$remote_version['config_version'] < $config['version']) { $remote_version['config_version'] < $config['version']) {
update_filter_reload_status("The other member is on older configuration version of {$g['product_name']}. Sync will not be done to prevent problems!"); update_filter_reload_status("The other member is on older configuration version. Sync will not be done to prevent problems!");
log_error("The other member is on older configuration version of {$g['product_name']}. Sync will not be done to prevent problems!"); log_error("The other member is on older configuration version. Sync will not be done to prevent problems!");
return false; return false;
} else { } else {
return true; return true;
......
...@@ -2,8 +2,8 @@ ...@@ -2,8 +2,8 @@
<?php <?php
/* /*
Copyright (C)2004 Bachman Kharazmi Copyright (C) 2004 Bachman Kharazmi
Copyright (C) 2003-2004 Manuel Kasper <mk@neon1.net>. Copyright (C) 2003-2004 Manuel Kasper <mk@neon1.net>
All rights reserved. All rights reserved.
Redistribution and use in source and binary forms, with or without Redistribution and use in source and binary forms, with or without
...@@ -34,9 +34,7 @@ require_once("system.inc"); ...@@ -34,9 +34,7 @@ require_once("system.inc");
$fp = fopen('php://stdin', 'r'); $fp = fopen('php://stdin', 'r');
echo "\n{$g['product_name']} will shutdown and halt system.\n"; echo "\nThe system will halt and power down. Do you want to proceed [y|n]? ";
echo "This may take a minute, depending on your hardware.\n";
echo "\nDo you want to proceed [y|n]? ";
if (strcasecmp(chop(fgets($fp)), 'y') == 0) { if (strcasecmp(chop(fgets($fp)), 'y') == 0) {
system_halt(true); system_halt(true);
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<?php <?php
/* /*
Copyright (C) 2003-2004 Manuel Kasper <mk@neon1.net>. Copyright (C) 2003-2004 Manuel Kasper <mk@neon1.net>
All rights reserved. All rights reserved.
Redistribution and use in source and binary forms, with or without Redistribution and use in source and binary forms, with or without
...@@ -33,9 +33,7 @@ require_once("system.inc"); ...@@ -33,9 +33,7 @@ require_once("system.inc");
$fp = fopen('php://stdin', 'r'); $fp = fopen('php://stdin', 'r');
echo "\n{$g['product_name']} will reboot.\n"; echo "\nThe system will reboot. Do you want to proceed [y|n]? ";
echo "This may take a minute, depending on your hardware.\n";
echo "\nDo you want to proceed [y|n]? ";
if (strcasecmp(chop(fgets($fp)), 'y') == 0) { if (strcasecmp(chop(fgets($fp)), 'y') == 0) {
system_reboot(true); system_reboot(true);
......
...@@ -302,10 +302,7 @@ function console_configure_ip_address($version) ...@@ -302,10 +302,7 @@ function console_configure_ip_address($version)
} }
} while (($ip_conflict === true) || !($is_ipaddr || $intip == '')); } while (($ip_conflict === true) || !($is_ipaddr || $intip == ''));
if ($intip != '') { if ($intip != '') {
echo "\n" . sprintf( echo "\n" . gettext("Subnet masks are entered as bit counts (like CIDR notation).") . "\n";
gettext("Subnet masks are entered as bit counts (as in CIDR notation) in %s."),
$g['product_name']
) . "\n";
if ($version === 6) { if ($version === 6) {
echo "e.g. ffff:ffff:ffff:ffff:ffff:ffff:ffff:ff00 = 120\n"; echo "e.g. ffff:ffff:ffff:ffff:ffff:ffff:ffff:ff00 = 120\n";
echo " ffff:ffff:ffff:ffff:ffff:ffff:ffff:0 = 112\n"; echo " ffff:ffff:ffff:ffff:ffff:ffff:ffff:0 = 112\n";
......
<?php <?php
/* /*
Copyright (C) 2015 Franco Fichtner <franco@opnsense.org> Copyright (C) 2015-2016 Franco Fichtner <franco@opnsense.org>
Copyright (C) 2014 Deciso B.V. Copyright (C) 2014 Deciso B.V.
Copyright (C) 2011 Scott Ullrich Copyright (C) 2011 Scott Ullrich
All rights reserved. All rights reserved.
......
...@@ -584,7 +584,7 @@ $( document ).ready(function() { ...@@ -584,7 +584,7 @@ $( document ).ready(function() {
<tbody> <tbody>
<tr> <tr>
<td> <td>
<?=gettext("Open a"); ?> <?=$g['[product_name']?> <?=gettext("configuration XML file and click the button below to restore the configuration."); ?> <?=gettext("Open a configuration XML file and click the button below to restore the configuration."); ?>
<br /><br /> <br /><br />
<?=gettext("Restore area:"); ?> <?=gettext("Restore area:"); ?>
<select name="restorearea" id="restorearea"> <select name="restorearea" id="restorearea">
......
...@@ -566,9 +566,9 @@ $(document).ready(function() { ...@@ -566,9 +566,9 @@ $(document).ready(function() {
</tr> </tr>
<tr> <tr>
<td colspan="2"><strong><span class="text-danger"><?=gettext("Note:")?></span></strong><br /> <td colspan="2"><strong><span class="text-danger"><?=gettext("Note:")?></span></strong><br />
<?=gettext("syslog sends UDP datagrams to port 514 on the specified " . <?=gettext("Syslog sends UDP datagrams to port 514 on the specified " .
"remote syslog server, unless another port is specified. Be sure to set syslogd on the " . "remote syslog server, unless another port is specified. Be sure to set syslogd on the " .
"remote server to accept syslog messages from");?> <?=$g['product_name']?>. "remote server to accept remote syslog messages.");?>
</td> </td>
</tr> </tr>
</table> </table>
......
...@@ -367,10 +367,10 @@ if (isset($config['trigger_initial_wizard'])) : ...@@ -367,10 +367,10 @@ if (isset($config['trigger_initial_wizard'])) :
<br /> <br />
<div class="content-box-main"> <div class="content-box-main">
<?php <?php
echo sprintf(gettext("Welcome to %s!\n"), $g['product_name']) . "<p>"; echo sprintf(gettext("Welcome to %s!"), $g['product_name']) . "<p>\n";
echo gettext("One moment while we start the initial setup wizard.") . "<p>\n"; echo gettext("One moment while we start the initial setup wizard.") . "<p>\n";
echo gettext("Embedded platform users: Please be patient, the wizard takes a little longer to run than the normal GUI.") . "<p>\n"; echo gettext("Embedded platform users: Please be patient, the wizard takes a little longer to run than the normal GUI.") . "<p>\n";
echo sprintf(gettext("To bypass the wizard, click on the %s logo on the initial page."), $g['product_name']) . "\n"; echo gettext("To bypass the wizard, click on the logo in the upper left corner.") . "\n";
?> ?>
</div> </div>
<div> <div>
......
...@@ -167,7 +167,7 @@ $main_buttons = array( ...@@ -167,7 +167,7 @@ $main_buttons = array(
<div class="container-fluid"> <div class="container-fluid">
<p> <p>
<span class="text-danger"><strong><?=gettext("Note:");?><br /></strong></span> <span class="text-danger"><strong><?=gettext("Note:");?><br /></strong></span>
<?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']);?> <?= 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.");?>
</p> </p>
</div> </div>
</form> </form>
......
...@@ -150,7 +150,7 @@ $main_buttons = array( ...@@ -150,7 +150,7 @@ $main_buttons = array(
<div class="container-fluid"> <div class="container-fluid">
<p> <p>
<span class="text-danger"><strong><?=gettext("Note:");?><br /></strong></span> <span class="text-danger"><strong><?=gettext("Note:");?><br /></strong></span>
<?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']);?> <?= 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.");?>
</p> </p>
</div> </div>
</form> </form>
......
...@@ -54,7 +54,7 @@ if (!$authcfg) { ...@@ -54,7 +54,7 @@ if (!$authcfg) {
} else { } else {
echo "<table class='table table-striped'>"; echo "<table class='table table-striped'>";
echo "<tr><th colspan='2'>".sprintf(gettext("Testing %s LDAP settings... One moment please..."), $g['product_name'])."</th></tr>"; echo "<tr><th colspan='2'>".gettext("Testing LDAP settings... One moment please...")."</th></tr>";
echo "<tr><td>" . gettext("Attempting connection to") . " " . $authserver . "</td>"; echo "<tr><td>" . gettext("Attempting connection to") . " " . $authserver . "</td>";
if ($ldap_is_connected) { if ($ldap_is_connected) {
echo "<td><font color='green'>OK</font></td></tr>"; echo "<td><font color='green'>OK</font></td></tr>";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment