diff options
Diffstat (limited to 'etc/inc/config.inc')
-rw-r--r-- | etc/inc/config.inc | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/etc/inc/config.inc b/etc/inc/config.inc index 1485669..78163fe 100644 --- a/etc/inc/config.inc +++ b/etc/inc/config.inc @@ -97,10 +97,10 @@ if($g['booting'] && file_exists("/cf/conf/config.xml")) { if(stristr($config_contents, "<m0n0wall>") == true) { if($g['booting']) echo "."; /* user has just upgraded to m0n0wall, replace root xml tags */ - log_error("Upgrading m0n0wall configuration to pfSense... "); + log_error(gettext("Upgrading m0n0wall configuration to pfSense... ")); $config_contents = str_replace("m0n0wall","pfsense", $config_contents); if (!config_validate("{$g['conf_path']}/config.xml")) - log_error("ERROR! Could not convert m0n0wall -> pfsense in config.xml"); + log_error(gettext("ERROR! Could not convert m0n0wall -> pfsense in config.xml")); conf_mount_rw(); $fd = fopen("/cf/conf/config.xml", "w"); fwrite($fd, $config_contents); @@ -130,9 +130,10 @@ else if ($g['booting'] and !file_exists($g['cf_conf_path'] . "/config.xml") ) { } } $cfgfstype = "msdosfs"; - echo "CDROM build\n"; - echo " CFG: {$cfgpartition}\n"; - echo " TYPE: {$cfgfstype}\n"; + echo gettext("CDROM build") . "\n"; + echo " " . gettext("CFG:") . " {$cfgpartition}\n"; + echo " " . gettext("CFG:") . " {$cfgpartition}\n"; + echo " " . gettext("TYPE:") . " {$cfgfstype}\n"; } else { if($g['booting']) echo "."; /* probe kernel known disks until we find one with config.xml */ @@ -147,7 +148,7 @@ else if ($g['booting'] and !file_exists($g['cf_conf_path'] . "/config.xml") ) { $cfgdevice = $mountdisk; $cfgpartition = $cfgdevice . "a"; $cfgfstype = "ufs"; - echo "Found configuration on $cfgdevice.\n"; + printf(gettext("Found configuration on %s.%s"), $cfgdevice, "\n"); } mwexec("/sbin/umount -f {$g['cf_path']}"); @@ -162,7 +163,7 @@ else if ($g['booting'] and !file_exists($g['cf_conf_path'] . "/config.xml") ) { $cfgdevice = $mountdisk; $cfgpartition = $cfgdevice . "d"; $cfgfstype = "ufs"; - echo "Found configuration on $cfgdevice.\n"; + printf(gettext("Found configuration on %s.%s"), $cfgdevice, "\n"); } mwexec("/sbin/umount -f {$g['cf_path']}"); @@ -176,11 +177,11 @@ else if ($g['booting'] and !file_exists($g['cf_conf_path'] . "/config.xml") ) { if (!$cfgdevice) { $last_backup = discover_last_backup(); if($last_backup) { - log_error("No config.xml found, attempting last known config restore."); - file_notice("config.xml", "No config.xml found, attempting last known config restore.", "pfSenseConfigurator", ""); + log_error(gettext("No config.xml found, attempting last known config restore.")); + file_notice("config.xml", gettext("No config.xml found, attempting last known config restore."), "pfSenseConfigurator", ""); restore_backup("/cf/conf/backup/{$last_backup}"); } else { - log_error("No config.xml or config backups found, resetting to factory defaults."); + log_error(gettext("No config.xml or config backups found, resetting to factory defaults.")); restore_backup('/conf.default/config.xml'); } } |