diff --git a/e107_admin/cron.php b/e107_admin/cron.php index 1a0c6fd27..9b9a37f7a 100644 --- a/e107_admin/cron.php +++ b/e107_admin/cron.php @@ -442,7 +442,8 @@ class cron_admin_ui extends e_admin_ui $obj = new $class_name; if (method_exists($obj, $method_name)) { - $mes->add("Executing config function ".$class_name." : ".$method_name."()", E_MESSAGE_DEBUG); + $message = str_replace('[function]', $class_name." : ".$method_name, LAN_CRON_55); + $mes->add($message, E_MESSAGE_DEBUG); if ($return == 'boolean') { call_user_func(array($obj, $method_name)); @@ -455,7 +456,8 @@ class cron_admin_ui extends e_admin_ui } else { - $mes->add("Config function ".$method_name."() NOT found.", E_MESSAGE_DEBUG); + $message = str_replace('[method]', $method_name."()", LAN_CRON_56); + $mes->add($message, E_MESSAGE_DEBUG); } } return FALSE; diff --git a/e107_admin/db.php b/e107_admin/db.php index a140125d7..42b49246f 100644 --- a/e107_admin/db.php +++ b/e107_admin/db.php @@ -104,15 +104,15 @@ if(e_AJAX_REQUEST ) $zip = e107::getFile()->zip($data, e_BACKUP.$newFile.".zip"); - echo "File backup complete! (".$zip.")
"; + echo DBLAN_60." (".$zip.")
"; - echo "Starting database backup...
"; + echo DBLAN_61."
"; $dbfile = e107::getDb()->backup('*', $newFile.".sql", array('nologs'=>1, 'droptable'=>1)); - echo "Database backup complete! (".$dbfile.")"; + echo DBLAN_62." (".$dbfile.")"; - e107::getAdminLog()->addSuccess($zip." ".$dbfile, false)->save('Full site backup completed.'); + e107::getAdminLog()->addSuccess($zip." ".$dbfile, false)->save(DBLAN_63); } @@ -175,9 +175,9 @@ class system_tools 'importForm' => array('diz'=>DBLAN_59, 'label'=> DBLAN_59), 'exportForm' => array('diz'=>DBLAN_58, 'label'=> DBLAN_58), 'sc_override_scan' => array('diz'=>DBLAN_55, 'label'=> DBLAN_56), - 'convert_to_utf8' => array('diz'=>'Check Database Charset','label'=>'Check Charset'), - 'correct_perms' => array('diz'=>'Correct File and Directory permissions','label'=>'Correct Perms'), - 'backup' => array('diz'=>'Backup Database, Files and Folders','label'=>'Backup Site') + 'convert_to_utf8' => array('diz'=>DBLAN_64,'label'=>DBLAN_65), + 'correct_perms' => array('diz'=>DBLAN_66,'label'=>DBLAN_67), + 'backup' => array('diz'=>DBLAN_68,'label'=>DBLAN_69) ); if(vartrue($_SERVER['E_DEV'])) @@ -307,8 +307,8 @@ class system_tools $mes = e107::getMessage(); - $message = "This will create a database dump and a zipped backup of all non-core plugins, your site theme, your media files and system logs"; - $message .= "
".LAN_CREATE.""; + $message = DBLAN_70; + $message .= "
".LAN_CREATE.""; $mes->addInfo($message); @@ -339,10 +339,10 @@ class system_tools } else { - $mes->addSuccess("Folder and File permissions have been updated"); + $mes->addSuccess(DBLAN_72); } - e107::getRender()->tablerender(DBLAN_10.SEP."Correcting File and Directory Permissions", $mes->render()); + e107::getRender()->tablerender(DBLAN_10.SEP.DBLAN_73, $mes->render()); } @@ -359,14 +359,14 @@ class system_tools if($connect = $sql->connect($server,$user, $pass, true)) { - $mes->addSuccess("Connecting to server"); + $mes->addSuccess(DBLAN_74); if(vartrue($_POST['createdb'])) { if($sql->gen("CREATE DATABASE ".$database." CHARACTER SET `utf8`")) { - $mes->addSuccess("Creating Database"); + $mes->addSuccess(DBLAN_75); // $sql->gen("CREATE USER ".$user."@'".$server."' IDENTIFIED BY '".$pass."';"); $sql->gen("GRANT ALL ON `".$database."`.* TO ".$user."@'".$server."';"); @@ -374,17 +374,17 @@ class system_tools } else { - $mes->addError("Creating Database"); + $mes->addError(DBLAN_75); return; } } if(!$sql->database($database)) { - $mes->addError("Selecting database"); + $mes->addError(DBLAN_76); } - $mes->addSuccess("Selecting database"); + $mes->addSuccess(DBLAN_76); if($this->multiSiteCreateTables($sql, $prefix)) { @@ -396,7 +396,7 @@ class system_tools } else { - $mes->addSuccess("Connecting to server"); + $mes->addSuccess(DBLAN_74); } if($error = $sql->getLastErrorText()) @@ -418,7 +418,7 @@ class system_tools if (!$sql_data) { - $mes->addError("Couldn't read core sql file"); + $mes->addError(DBLAN_77); } preg_match_all("/create(.*?)(?:myisam|innodb);/si", $sql_data, $result ); @@ -455,16 +455,17 @@ class system_tools if(!isset($POST['create_multisite'])) { - $mes->addInfo("This will create a fresh installation of e107 at the domain you specify. Using your server administration software (eg. cPanel) - park your other domain on top of ".e_DOMAIN); + $info = str_replace('[domain]', e_DOMAIN, LANINS_133); + $mes->addInfo($info); } $text = $frm->open('multisite')." - + "; @@ -597,10 +598,10 @@ class system_tools - - - - + + + + "; @@ -636,29 +637,27 @@ class system_tools if($invalidCollations == true) { - //TODO LAN - $message = ' - This function will permanently modify all tables in your database. ('.$config['mySQLdefaultdb'].')
- It is HIGHLY recommended that you first backup your database and switch your site into maintenance mode. -
-
- Please note: - - '; - + $message = str_replace('[database]', $config['mySQLdefaultdb'], DBLAN_82); + $message .= '
'; + $message .= DBLAN_83; + $message .= '
'; + $message .= '
'; + $message .= DBLAN_84; + $message .= ''; + $mes->add($message, E_MESSAGE_WARNING); $text .= "
- "."Convert Database"." + ".DBLAN_89."
- ".$frm->admin_button('perform_utf8_convert', "Convert non-UTF8 Tables",false,"Convert non-UTF8 Tables",'class=btn-success&data-loading-text=Please wait...')." + ".$frm->admin_button('perform_utf8_convert', DBLAN_90,false,DBLAN_90,'class=btn-success&data-loading-text='.DBLAN_91)."
"; @@ -666,7 +665,7 @@ class system_tools } else { - $mes->addSuccess("Your tables are using the correct character set."); + $mes->addSuccess(DBLAN_92); } @@ -788,11 +787,11 @@ class system_tools } elseif($ERROR != TRUE) { - $message = "Database Converted successfully to UTF-8. "; + $message = DBLAN_93; //$message .= "
Please now add the following line to your e107_config.php file:
\$mySQLcharset = 'utf8';"; $mes->add($message, E_MESSAGE_SUCCESS); - $mes->addSuccess("Please make sure you have the following line in your e107_config.php file:"); + $mes->addSuccess(DBLAN_94); $mes->addSuccess('$mySQLcharset = "utf8";'); } @@ -1004,12 +1003,9 @@ class system_tools $mes = e107::getMessage(); $frm = e107::getSingleton('e_form'); - - //TODO LANs - $text = "
- Export Options + ".DBLAN_95."
- - The parked domain which will become a new e107 website. + + ".LANINS_131."
TableEngineCollationStatus".DBLAN_78."".DBLAN_79."".DBLAN_80."".DBLAN_81."
@@ -1017,8 +1013,8 @@ class system_tools - - + + @@ -1053,8 +1049,8 @@ class system_tools - - + + @@ -1067,7 +1063,7 @@ class system_tools $checked = (vartrue($_POST['xml_tables'][$name]) == $name) ? 1: 0; $text .= ""; @@ -1092,7 +1088,7 @@ class system_tools @@ -1100,13 +1096,13 @@ class system_tools
".$frm->checkbox_toggle('check-all-verify', 'xml_prefs')." PreferencesRows".$frm->checkbox_toggle('check-all-verify', 'xml_prefs')." ".DBLAN_96."".DBLAN_98."
".$frm->checkbox_toggle('check-all-verify', 'xml_tables')."TablesRows".$frm->checkbox_toggle('check-all-verify', 'xml_tables').DBLAN_97."".DBLAN_98."
- ".$frm->checkbox("xml_tables[".$name."]", $name, $checked, array('label'=>"Table Data: ".$name)). + ".$frm->checkbox("xml_tables[".$name."]", $name, $checked, array('label'=>DBLAN_99." ".$name)). " $count
"; $checked = (vartrue($_POST['package_images'])) ? 1: 0; - $text .= $frm->checkbox("package_images",'package_images', $checked)." Convert paths and package images and xml into: ".e107::getParser()->replaceConstants(EXPORT_PATH)." + $text .= $frm->checkbox("package_images",'package_images', $checked)." ".DBLAN_100." ".e107::getParser()->replaceConstants(EXPORT_PATH)."
- ".$frm->admin_button('exportXmlFile', "Export File", 'other')." + ".$frm->admin_button('exportXmlFile', DBLAN_101, 'other')."
"; - e107::getRender()->tablerender(DBLAN_10.SEP."Export Options",$mes->render(). $text); + e107::getRender()->tablerender(DBLAN_10.SEP.DBLAN_102,$mes->render(). $text); } @@ -1121,12 +1117,12 @@ class system_tools foreach($ret['success'] as $table) { - e107::getMessage()->addSuccess("Inserted $table"); + e107::getMessage()->addSuccess(DBLAN_103." $table"); } foreach($ret['failed'] as $table) { - e107::getMessage()->addError("Failed to Insert $table"); + e107::getMessage()->addError(DBLAN_104." $table"); } } @@ -1279,12 +1275,11 @@ class system_tools //$pref['sc_override'] = $scList; //save_prefs(); // $mes->add(DBLAN_57.':
'.$pref['sc_override'], E_MESSAGE_SUCCESS); - // FIXME lan e107::getRender()->tablerender( ''.DBLAN_56, DBLAN_57.': ' - .($config->get('sc_override') ? '
'.$config->get('sc_override') : '(empty)') - .'

Batch shortcodes:' - .($config->get('sc_batch_override') ? '
'.$config->get('sc_batch_override') : '(empty)') + .($config->get('sc_override') ? '
'.$config->get('sc_override') : DBLAN_106) + .'

'.DBLAN_105.'' + .($config->get('sc_batch_override') ? '
'.$config->get('sc_batch_override') : DBLAN_106) ); } @@ -1457,8 +1452,6 @@ function exportXmlFile($prefs,$tables,$package=FALSE,$debug=FALSE) $tp = e107::getParser(); $mes = e107::getMessage(); - //TODO LANs - if(vartrue($package)) { @@ -1473,7 +1466,8 @@ function exportXmlFile($prefs,$tables,$package=FALSE,$debug=FALSE) if(!is_writable($desinationFolder)) { - $mes->add($desinationFolder." is not writable", E_MESSAGE_ERROR); + $message = str_replace('[folder]', $desinationFolder, DBLAN_107); + $mes->add($message, E_MESSAGE_ERROR); return ; } } @@ -1481,7 +1475,7 @@ function exportXmlFile($prefs,$tables,$package=FALSE,$debug=FALSE) if($xml->e107Export($prefs,$tables,$debug)) { - $mes->add("Created: ".$desinationFolder."install.xml", E_MESSAGE_SUCCESS); + $mes->add(DBLAN_108." ".$desinationFolder."install.xml", E_MESSAGE_SUCCESS); if(varset($xml->fileConvertLog)) { foreach($xml->fileConvertLog as $oldfile) @@ -1490,11 +1484,11 @@ function exportXmlFile($prefs,$tables,$package=FALSE,$debug=FALSE) $newfile = $desinationFolder.$file; if($oldfile == $newfile || (copy($oldfile,$newfile))) { - $mes->add("Copied: ".$newfile, E_MESSAGE_SUCCESS); + $mes->add(DBLAN_109." ".$newfile, E_MESSAGE_SUCCESS); } else { - $mes->add("Couldn't copy: ".$newfile, E_MESSAGE_ERROR); + $mes->add(DBLAN_110." ".$newfile, E_MESSAGE_ERROR); } } } diff --git a/e107_languages/English/admin/lan_cron.php b/e107_languages/English/admin/lan_cron.php index c8d2a4d9b..95c84fd57 100644 --- a/e107_languages/English/admin/lan_cron.php +++ b/e107_languages/English/admin/lan_cron.php @@ -88,6 +88,8 @@ define("LAN_CRON_52", "Day(s):"); define("LAN_CRON_53", "Month(s):"); define("LAN_CRON_54", "Weekday(s):"); +define("LAN_CRON_55", "Executing config function [b][function][/b]"); +define("LAN_CRON_56", "Config function [b][method][/b] NOT found."); define("LAN_CRON_BACKUP", "Backup"); define("LAN_CRON_LOGGING", "Logging"); diff --git a/e107_languages/English/admin/lan_db.php b/e107_languages/English/admin/lan_db.php index 81d63ecd0..36d6cf364 100644 --- a/e107_languages/English/admin/lan_db.php +++ b/e107_languages/English/admin/lan_db.php @@ -70,4 +70,63 @@ define('DBLAN_57', 'Shortcode Override list set to'); define('DBLAN_58', "Export Site Data"); define('DBLAN_59', "Import Site Data"); +define('DBLAN_60', "File backup complete!"); +define('DBLAN_61', "Starting database backup..."); +define('DBLAN_62', "Database backup complete!"); +define('DBLAN_63', "Full site backup completed."); + +define('DBLAN_64', "Check Database Charset"); +define('DBLAN_65', "Check Charset"); +define('DBLAN_66', "Correct File and Directory permissions"); +define('DBLAN_67', "Correct Perms"); +define('DBLAN_68', "Backup Database, Files and Folders"); +define('DBLAN_69', "Backup Site"); + +define('DBLAN_70', "This will create a database dump and a zipped backup of all non-core plugins, your site theme, your media files and system logs"); +define('DBLAN_71', "Please wait..."); +define('DBLAN_72', "Folder and File permissions have been updated"); +define('DBLAN_73', "Correcting File and Directory Permissions"); +define('DBLAN_74', "Connecting to server"); +define('DBLAN_75', "Creating Database"); +define('DBLAN_76', "Selecting database"); +define('DBLAN_77', "Couldn't read core sql file"); + +define('DBLAN_78', "Table"); +define('DBLAN_79', "Engine"); +define('DBLAN_80', "Collation"); +define('DBLAN_81', "Status"); + +define('DBLAN_82', "This function will permanently modify all tables in your database. ([database])"); +define('DBLAN_83', "It is [b]HIGHLY[/b] recommended that you first backup your database and switch your site into maintenance mode."); +define('DBLAN_84', "Please note:"); +define('DBLAN_85', "The conversion process can take up to one minute or much much more depending on the size of your database."); +define('DBLAN_86', "The conversion does not work with serialized arrays."); +define('DBLAN_87', "Be sure that you have followed all steps of the upgrade process first."); +define('DBLAN_88', "Core prefs are ignored during the conversion process due to possibility of corruption."); + +define('DBLAN_89', "Convert Database"); +define('DBLAN_90', "Convert non-UTF8 Tables"); +define('DBLAN_91', "Please wait..."); +define('DBLAN_92', "Your tables are using the correct character set."); +define('DBLAN_93', "Database Converted successfully to UTF-8."); +define('DBLAN_94', "Please make sure you have the following line in your e107_config.php file:"); + +define('DBLAN_95', "Export Options"); +define('DBLAN_96', "Preferences"); +define('DBLAN_97', "Tables"); +define('DBLAN_98', "Rows"); +define('DBLAN_99', "Table Data:"); +define('DBLAN_100', "Convert paths and package images and xml into:"); +define('DBLAN_101', "Export File"); +define('DBLAN_102', "Export Options"); +define('DBLAN_103', "Inserted"); +define('DBLAN_104', "Failed to Insert"); +define('DBLAN_105', "Batch shortcodes:"); +define('DBLAN_106', "(empty)"); + +define('DBLAN_107', "[folder] is not writable"); +define('DBLAN_108', "Created:"); +define('DBLAN_109', "Copied:"); +define('DBLAN_110', "Couldn't copy:"); + ?> diff --git a/e107_languages/English/lan_installer.php b/e107_languages/English/lan_installer.php index e06265157..fa66bedeb 100644 --- a/e107_languages/English/lan_installer.php +++ b/e107_languages/English/lan_installer.php @@ -185,4 +185,8 @@ define("LANINS_126", "For security reasons you should now set the file permissio define("LANINS_127", "The database [x] already exists. Overwrite it? (any existing data will be lost)"); define("LANINS_128", "Overwrite"); define("LANINS_129", "Database not found."); - + +define('LANINS_130', "Parked Domain"); +define('LANINS_131', "The parked domain which will become a new e107 website."); +define('LANINS_132', "mydomain.com"); +define('LANINS_133', "This will create a fresh installation of e107 at the domain you specify. Using your server administration software (eg. cPanel) - park your other domain on top of [domain]");