Changeset 1158 in ExiteCMS for trunk/administration/tools/language_pack_English.php
- Timestamp:
- 12/03/07 21:40:54 (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/administration/tools/language_pack_English.php
r1145 r1158 11 11 | | 12 12 | for their efforts in making this translation file. | 13 | They can be reached on http://exitecms.exite.eu|13 | They can be contacted on http://exitecms.exite.eu | 14 14 +----------------------------------------------------+ 15 15 | Released under the terms & conditions of v2 of the | … … 17 17 | the included gpl.txt file or visit http://gnu.org | 18 18 +----------------------------------------------------*/ 19 if (!defined('CMS_SETUP')) require_once dirname(__FILE__)."/../../includes/core_functions.php"; 20 21 // check for the proper admin access rights 22 if (!CMS_CLI && (!checkrights("T") || !defined("iAUTH") || $aid != iAUTH)) fallback(ADMIN."index.php"); 23 24 // load the locale for this module 25 if (!CMS_CLI) locale_load("admin.main"); 26 27 /*---------------------------------------------------+ 28 | defines | 29 +----------------------------------------------------*/ 30 define('LP_LOCALE', "en"); 31 define('LP_LANGUAGE', "English"); 32 define('LP_LOCALES', "en_US|en_GB|english|eng"); 33 define('LP_CHARSET', "iso-8859-1"); 34 define('LP_VERSION', "7.00"); 35 define('LP_DATE', "1195160770"); 36 37 /*---------------------------------------------------+ 38 | local functions | 39 +----------------------------------------------------*/ 40 function load_localestrings($localestrings, $locales_name) { 41 global $step, $db_prefix; 42 43 // if this is an upgrade, remove the old locale strings first 44 if ($step == "upgrade") { 45 $result = dbquery("DELETE FROM ".$db_prefix."locales WHERE locales_code = '".LP_LOCALE."' AND locales_name = '$locales_name'"); 46 } 47 48 // proces the imported locale strings 49 foreach ($localestrings as $key => $value) { 50 if (is_array($value)) { 51 $value = "#ARRAY#\n".serialize($value); 52 } 53 $result = dbquery("INSERT INTO ".$db_prefix."locales (locales_code, locales_name, locales_key, locales_value, locales_datestamp) VALUES ('".LP_LOCALE."', '$locales_name', '".mysql_escape_string($key)."', '".mysql_escape_string($value)."', '".time()."')"); 54 } 55 return true; 56 } 57 58 function install_language_pack() { 59 global $step, $db_prefix; 60 61 if ($step == "install") { 62 $result = dbquery("INSERT INTO ".$db_prefix."locale (locale_code, locale_name, locale_locale, locale_charset, locale_active) VALUES ('en', 'English', 'en_US|en_GB|english|eng', 'iso-8859-1', 1)"); 63 } 19 function install_language_pack($step) { 20 21 $localestrings = array(); 22 $localestrings['404page'] = "<table border=\"0\" cellspacing=\"0\" cellpadding=\"5\" width=\"100%\" align=\"center\"> <tbody><tr><td width=\"10\"> </td><td><div align=\"center\"><font size=\"6\"><span class=\"shoutboxname\"><br />404 - Page Not Found</span><br /></font></div><br /><br /><hr width=\"90%\" size=\"2\" /><br /><br /><div align=\"center\">We are sorry, but the document you requested cannot be found on this server.<br /></div><br /><div align=\"center\">Most likely, this is a result of yet another reorganization of this Website to reflect our constant evolution and ongoing development, coupled with a transition from an old server with lots of legacy files to a shiny new server.<br /></div><br /><div align=\"center\">But then again, it might just be a completely random event and the result of too many cosmic rays. Who knows?<br /></div><br /><br /><hr width=\"90%\" size=\"2\" /><br /><br /><div align=\"center\">Your best bet for finding what you seek is to start at our home page (<a href=\"/\">click here to jump to the home page</a>), check out our menu, or use the search menu option.<br /></div><br /><div align=\"center\">If that doesn't work, and you think it's a document that should be here, please send a PM to the webmaster and let us know about it (registered users only).</div></td><td width=\"10\"> </td></tr></tbody></table><br />"; 23 load_localestrings($localestrings, LP_LOCALE, "404page", $step); 64 24 65 25 $localestrings = array(); … … 83 43 $localestrings['426'] = "UnCheck all"; 84 44 $localestrings['427'] = "Modules & Plugins"; 85 load_localestrings($localestrings, "admin.admins");45 load_localestrings($localestrings, LP_LOCALE, "admin.admins", $step); 86 46 87 47 $localestrings = array(); … … 104 64 $localestrings['465'] = "The blacklist is currently empty."; 105 65 $localestrings['470'] = "Blacklisted because of an offensive, rude or inappropriate comments posting"; 106 load_localestrings($localestrings, "admin.blacklist");66 load_localestrings($localestrings, LP_LOCALE, "admin.blacklist", $step); 107 67 108 68 $localestrings = array(); … … 116 76 $localestrings['414'] = "Delete Comment?"; 117 77 $localestrings['415'] = "There are no comments for this item."; 118 load_localestrings($localestrings, "admin.comments");78 load_localestrings($localestrings, LP_LOCALE, "admin.comments", $step); 119 79 120 80 $localestrings = array(); … … 142 102 $localestrings['436'] = "Preview Page"; 143 103 $localestrings['437'] = "Save Page"; 144 load_localestrings($localestrings, "admin.custom_pages");104 load_localestrings($localestrings, LP_LOCALE, "admin.custom_pages", $step); 145 105 146 106 $localestrings = array(); … … 193 153 $localestrings['480'] = "Restore Backup"; 194 154 $localestrings['481'] = "Filename:"; 195 load_localestrings($localestrings, "admin.db-backup");155 load_localestrings($localestrings, LP_LOCALE, "admin.db-backup", $step); 196 156 197 157 $localestrings = array(); … … 255 215 $localestrings['511'] = " to go to Download Categories"; 256 216 $localestrings['512'] = "Sub Category of"; 257 $localestrings['520'] = "Download Bars Panel Content"; 258 $localestrings['521'] = "Bar Position"; 259 $localestrings['522'] = "Save Bar Content"; 260 $localestrings['523'] = "Download Bars Panel Content succesfully saved"; 261 $localestrings['524'] = "Download Bars Title"; 262 load_localestrings($localestrings, "admin.downloads"); 217 $localestrings['513'] = " for the locale "; 218 $localestrings['514'] = "Category Locale:"; 219 $localestrings['515'] = ""; 220 load_localestrings($localestrings, LP_LOCALE, "admin.downloads", $step); 263 221 264 222 $localestrings = array(); … … 288 246 $localestrings['486'] = "No FAQ Categories defined."; 289 247 $localestrings['487'] = "Delete FAQ?"; 290 load_localestrings($localestrings, "admin.faq");248 load_localestrings($localestrings, LP_LOCALE, "admin.faq", $step); 291 249 292 250 $localestrings = array(); … … 350 308 $localestrings['492'] = "Move down"; 351 309 $localestrings['493'] = "Refresh Forum Ordering"; 352 load_localestrings($localestrings, "admin.forums");310 load_localestrings($localestrings, LP_LOCALE, "admin.forums", $step); 353 311 354 312 $localestrings = array(); … … 435 393 $localestrings['FPM_301'] = "Public - show who voted for which item"; 436 394 $localestrings['FPM_400'] = "For the forums marked <font color='green'>green</font>, special settings have been defined. For forums marked <font color='red'>red</font>, global settings are used"; 437 load_localestrings($localestrings, "admin.forum_polls");395 load_localestrings($localestrings, LP_LOCALE, "admin.forum_polls", $step); 438 396 439 397 $localestrings = array(); … … 459 417 $localestrings['464'] = "Update image list for TinyMCE editor"; 460 418 $localestrings['465'] = "Cancel"; 461 load_localestrings($localestrings, "admin.image_uploads");419 load_localestrings($localestrings, LP_LOCALE, "admin.image_uploads", $step); 462 420 463 421 $localestrings = array(); … … 522 480 $localestrings['308'] = "While processing the language pack for %s (%s), an error occured. The error is:"; 523 481 $localestrings['309'] = "You can not install this language pack. This pack is for ExiteCMS version"; 524 load_localestrings($localestrings, "admin.main");482 load_localestrings($localestrings, LP_LOCALE, "admin.main", $step); 525 483 526 484 $localestrings = array(); … … 580 538 $localestrings['478'] = "Return to Members Admin"; 581 539 $localestrings['479'] = "Return to Admin Index"; 582 load_localestrings($localestrings, "admin.members");540 load_localestrings($localestrings, LP_LOCALE, "admin.members", $step); 583 541 584 542 $localestrings = array(); … … 613 571 $localestrings['mod004'] = "This module can not be installed. Required information is missing from the modules installer.<br />"; 614 572 $localestrings['mod005'] = "This module does not function beyond ExiteCMS revision level %s.<br />"; 615 load_localestrings($localestrings, "admin.modules");573 load_localestrings($localestrings, LP_LOCALE, "admin.modules", $step); 616 574 617 575 $localestrings = array(); … … 715 673 $localestrings['553'] = "Select a language:"; 716 674 $localestrings['554'] = "for the locale"; 717 load_localestrings($localestrings, "admin.news-articles");675 load_localestrings($localestrings, LP_LOCALE, "admin.news-articles", $step); 718 676 719 677 $localestrings = array(); … … 748 706 $localestrings['444'] = "Down"; 749 707 $localestrings['445'] = "Move to the upper body section"; 750 $localestrings['446'] = "Move to lower body section";708 $localestrings['446'] = "Move to the lower body section"; 751 709 $localestrings['447'] = "No"; 752 710 $localestrings['448'] = "Yes"; … … 785 743 $localestrings['488'] = "Select a language:"; 786 744 $localestrings['489'] = "for the locale"; 787 load_localestrings($localestrings, "admin.panels"); 745 $localestrings['490'] = "Header Panels"; 746 $localestrings['491'] = "Footer Panels"; 747 $localestrings['492'] = "Header"; 748 $localestrings['493'] = "Footer"; 749 $localestrings['494'] = "Move to the header section"; 750 $localestrings['495'] = "Move to the footer section"; 751 load_localestrings($localestrings, LP_LOCALE, "admin.panels", $step); 788 752 789 753 $localestrings = array(); … … 799 763 $localestrings['425'] = "No"; 800 764 $localestrings['426'] = "RegEx"; 765 $localestrings['427'] = "Retain URL parameters"; 801 766 $localestrings['430'] = "Add this redirect URL"; 802 767 $localestrings['431'] = "Save this redirect URL"; … … 804 769 $localestrings['433'] = "Delete"; 805 770 $localestrings['480'] = "No Redirect URLs present"; 806 $localestrings['481'] = "Note: the URL's you type here are relative to the root of the website, and should start with a '/'.<br />\n Make sure you're not defining a redirect forany of the existing website functions (like /index.php)!";771 $localestrings['481'] = "Note: the URL's you type here are relative to the root of the website, and should start with a '/'.<br />\nYou can not redirect any of the existing website functions (like /index.php)!"; 807 772 $localestrings['482'] = "New redirect URL saved successfully"; 808 773 $localestrings['483'] = "Redirect URL saved successfully"; … … 814 779 $localestrings['489'] = "Requested url_id is missing. Maybe it was deleted by someone else?"; 815 780 $localestrings['490'] = "If checked, the first field is used to match, the second to convert the URL"; 816 load_localestrings($localestrings, "admin.redirects"); 781 $localestrings['491'] = "If checked, any parameters given will be appended to the new URL"; 782 $localestrings['492'] = "If checked, the site will redirect to the exact URL given"; 783 load_localestrings($localestrings, LP_LOCALE, "admin.redirects", $step); 817 784 818 785 $localestrings = array(); … … 884 851 $localestrings['556'] = "Text"; 885 852 $localestrings['557'] = "New members activated by admin?"; 886 $localestrings['558'] = "Site localisation method:"; 887 $localestrings['559'] = "No localisation (fixed layout)"; 888 $localestrings['560'] = "Single tree content (symmetric layout)"; 889 $localestrings['561'] = "Multiple tree content (a-symmetic layout)"; 853 $localestrings['558'] = "Localisation methods"; 854 $localestrings['559'] = "No localisation, all text is hardcoded"; 855 $localestrings['560'] = "Assign multiple languages to a single item"; 856 $localestrings['561'] = "Assign multiple items to a single language"; 857 $localestrings['570'] = "Panels:"; 858 $localestrings['571'] = "Menu sytem:"; 859 $localestrings['572'] = "Articles:"; 860 $localestrings['573'] = "News:"; 861 $localestrings['574'] = "Downloads:"; 890 862 $localestrings['600'] = "Image"; 891 863 $localestrings['601'] = "Thumb size:"; … … 948 920 $localestrings['803'] = "Attachments deleted: "; 949 921 $localestrings['850'] = "Languages"; 950 load_localestrings($localestrings, "admin.settings");922 load_localestrings($localestrings, LP_LOCALE, "admin.settings", $step); 951 923 952 924 $localestrings = array(); … … 988 960 $localestrings['451'] = "Select a language:"; 989 961 $localestrings['452'] = "for the locale"; 990 load_localestrings($localestrings, "admin.sitelinks");962 load_localestrings($localestrings, LP_LOCALE, "admin.sitelinks", $step); 991 963 992 964 $localestrings = array(); … … 1008 980 $localestrings['422'] = "General error"; 1009 981 $localestrings['430'] = "For more detailed information on these upgrades, check the changelogs on <a href='http://exitecms.exite.eu' alt='' target='_blank'>http://exitecms.exite.eu</a>"; 1010 load_localestrings($localestrings, "admin.upgrade");982 load_localestrings($localestrings, LP_LOCALE, "admin.upgrade", $step); 1011 983 1012 984 $localestrings = array(); … … 1063 1035 $localestrings['451'] = "Visible in user profiles:"; 1064 1036 $localestrings['452'] = "Visible in Forum posts:"; 1065 load_localestrings($localestrings, "admin.user_groups");1037 load_localestrings($localestrings, LP_LOCALE, "admin.user_groups", $step); 1066 1038 1067 1039 $localestrings = array(); … … 1089 1061 $localestrings['utf-7'] = "Unicode (UTF-7)"; 1090 1062 $localestrings['utf-8'] = "Unicode (UTF-8)"; 1091 load_localestrings($localestrings, "charsets");1063 load_localestrings($localestrings, LP_LOCALE, "charsets", $step); 1092 1064 1093 1065 $localestrings = array(); … … 1109 1081 $localestrings['white'] = "White"; 1110 1082 $localestrings['yellow'] = "Yellow"; 1111 load_localestrings($localestrings, "colors");1083 load_localestrings($localestrings, LP_LOCALE, "colors", $step); 1112 1084 1113 1085 $localestrings = array(); … … 1149 1121 $localestrings['ca'] = "Canada"; 1150 1122 $localestrings['cc'] = "Cocos (Keeling) Islands"; 1151 $localestrings['cd'] = " The Democratic Republic Of The Congo";1123 $localestrings['cd'] = "Congo, The Democratic Republic Of The"; 1152 1124 $localestrings['cf'] = "Central African Republic"; 1153 1125 $localestrings['cg'] = "Congo"; … … 1271 1243 $localestrings['ng'] = "Nigeria"; 1272 1244 $localestrings['ni'] = "Nicaragua"; 1273 $localestrings['nl'] = " The Netherlands";1245 $localestrings['nl'] = "Netherlands, The"; 1274 1246 $localestrings['no'] = "Norway"; 1275 1247 $localestrings['np'] = "Nepal"; … … 1347 1319 $localestrings['zm'] = "Zambia"; 1348 1320 $localestrings['zw'] = "Zimbabwe"; 1349 load_localestrings($localestrings, "countrycode");1321 load_localestrings($localestrings, LP_LOCALE, "countrycode", $step); 1350 1322 1351 1323 $localestrings = array(); … … 1605 1577 $localestrings['Zambia'] = "zm"; 1606 1578 $localestrings['Zimbabwe'] = "zw"; 1607 load_localestrings($localestrings, "countryname");1579 load_localestrings($localestrings, LP_LOCALE, "countryname", $step); 1608 1580 1609 1581 $localestrings = array(); … … 1841 1813 $localestrings['zm'] = "Kwacha"; 1842 1814 $localestrings['zw'] = "Zimbabwian Dollars"; 1843 load_localestrings($localestrings, "currency");1815 load_localestrings($localestrings, LP_LOCALE, "currency", $step); 1844 1816 1845 1817 $localestrings = array(); … … 2077 2049 $localestrings['zm'] = "ZMK"; 2078 2050 $localestrings['zw'] = "ZWD"; 2079 load_localestrings($localestrings, "currencycode");2051 load_localestrings($localestrings, LP_LOCALE, "currencycode", $step); 2080 2052 2081 2053 $localestrings = array(); … … 2163 2135 $localestrings['580'] = "skype"; 2164 2136 $localestrings['581'] = "Top"; 2165 load_localestrings($localestrings, "forum.main");2137 load_localestrings($localestrings, LP_LOCALE, "forum.main", $step); 2166 2138 2167 2139 $localestrings = array(); … … 2196 2168 $localestrings['464'] = "No matches found, please try again."; 2197 2169 $localestrings['465'] = "Please specify at least one word to search for."; 2198 load_localestrings($localestrings, "forum.options");2170 load_localestrings($localestrings, LP_LOCALE, "forum.options", $step); 2199 2171 2200 2172 $localestrings = array(); … … 2304 2276 $localestrings['550'] = "Thread Reply Notification - {THREAD_SUBJECT}"; 2305 2277 $localestrings['551'] = "Hello {USERNAME},\n\nA reply has been posted in the forum thread '{THREAD_SUBJECT}' which you are tracking at {SITE_NAME}. You can use the following link to view the reply:\n\n{THREAD_URL}\n\nIf you no longer wish to watch this thread you can click the 'Tracking Off' button located at the bottom of the thread.\n\nRegards,\n{SITE_WEBMASTER}."; 2306 load_localestrings($localestrings, "forum.post");2278 load_localestrings($localestrings, LP_LOCALE, "forum.post", $step); 2307 2279 2308 2280 $localestrings = array(); … … 2311 2283 $localestrings['402'] = "<b>New this week</b>"; 2312 2284 $localestrings['403'] = "No Articles have been added to this Category"; 2313 load_localestrings($localestrings, "main.articles");2285 load_localestrings($localestrings, LP_LOCALE, "main.articles", $step); 2314 2286 2315 2287 $localestrings = array(); … … 2323 2295 $localestrings['407'] = "No Article Categories defined"; 2324 2296 $localestrings['408'] = "of"; 2325 load_localestrings($localestrings, "main.article_cats");2297 load_localestrings($localestrings, LP_LOCALE, "main.article_cats", $step); 2326 2298 2327 2299 $localestrings = array(); … … 2335 2307 $localestrings['c107'] = " Disable smileys in this comment"; 2336 2308 $localestrings['c108'] = "Toggle smileys"; 2337 load_localestrings($localestrings, "main.comments");2309 load_localestrings($localestrings, LP_LOCALE, "main.comments", $step); 2338 2310 2339 2311 $localestrings = array(); … … 2354 2326 $localestrings['442'] = "Your message was not sent for the following reason(s):"; 2355 2327 $localestrings['443'] = "Please try again."; 2356 load_localestrings($localestrings, "main.contact");2328 load_localestrings($localestrings, LP_LOCALE, "main.contact", $step); 2357 2329 2358 2330 $localestrings = array(); … … 2360 2332 $localestrings['401'] = "Internal Error"; 2361 2333 $localestrings['402'] = "Unable to retrieve page content."; 2362 load_localestrings($localestrings, "main.custom_pages");2334 load_localestrings($localestrings, LP_LOCALE, "main.custom_pages", $step); 2363 2335 2364 2336 $localestrings = array(); … … 2378 2350 $localestrings['430'] = "No Download Categories defined"; 2379 2351 $localestrings['431'] = "No Downloads have been added to this Category"; 2380 load_localestrings($localestrings, "main.downloads");2352 load_localestrings($localestrings, LP_LOCALE, "main.downloads", $step); 2381 2353 2382 2354 $localestrings = array(); … … 2387 2359 $localestrings['420'] = "Question:"; 2388 2360 $localestrings['421'] = "Answer:"; 2389 load_localestrings($localestrings, "main.faq");2361 load_localestrings($localestrings, LP_LOCALE, "main.faq", $step); 2390 2362 2391 2363 $localestrings = array(); 2392 2364 $localestrings['400'] = "Forum:"; 2393 load_localestrings($localestrings, "main.feeds");2365 load_localestrings($localestrings, LP_LOCALE, "main.feeds", $step); 2394 2366 2395 2367 $localestrings = array(); … … 2521 2493 $localestrings['usera'] = "Anonymous"; 2522 2494 $localestrings['userf1'] = "Moderator"; 2523 load_localestrings($localestrings, "main.global");2495 load_localestrings($localestrings, LP_LOCALE, "main.global", $step); 2524 2496 2525 2497 $localestrings = array(); … … 2536 2508 $localestrings['410'] = "Hello [USER_NAME],\n\nYou have or someone has requested a new password to access your [SITENAME] account.\n\nTo change your password please click the following link:\n\n[NEW_PASS_LINK]\n\nRegards,\n[SITEUSERNAME]"; 2537 2509 $localestrings['411'] = "Hello [USER_NAME],\n\nYour new password to access your [SITENAME] account is:\n\n[NEW_PASS]\n\nRegards,\n[SITEUSERNAME]"; 2538 load_localestrings($localestrings, "main.lostpassword");2510 load_localestrings($localestrings, LP_LOCALE, "main.lostpassword", $step); 2539 2511 2540 2512 $localestrings = array(); … … 2578 2550 $localestrings['491'] = "We have detected that your email address is no longer valid.<br />Your accounts will be deactivated in %s days."; 2579 2551 $localestrings['499'] = "<br /><br />Please update your profile now."; 2580 load_localestrings($localestrings, "main.members-profile");2552 load_localestrings($localestrings, LP_LOCALE, "main.members-profile", $step); 2581 2553 2582 2554 $localestrings = array(); … … 2589 2561 $localestrings['406'] = "Show All Categories"; 2590 2562 $localestrings['407'] = "No News Categories defined"; 2591 load_localestrings($localestrings, "main.news_cats");2563 load_localestrings($localestrings, LP_LOCALE, "main.news_cats", $step); 2592 2564 2593 2565 $localestrings = array(); … … 2735 2707 $localestrings['639'] = "Headers only"; 2736 2708 $localestrings['640'] = "Message details"; 2737 load_localestrings($localestrings, "main.pm");2709 load_localestrings($localestrings, LP_LOCALE, "main.pm", $step); 2738 2710 2739 2711 $localestrings = array(); … … 2741 2713 $localestrings['401'] = " on "; 2742 2714 $localestrings['402'] = "Extended News"; 2743 load_localestrings($localestrings, "main.print");2715 load_localestrings($localestrings, LP_LOCALE, "main.print", $step); 2744 2716 2745 2717 $localestrings = array(); … … 2761 2733 $localestrings['r123'] = "Average"; 2762 2734 $localestrings['r124'] = "Poor"; 2763 load_localestrings($localestrings, "main.ratings");2735 load_localestrings($localestrings, LP_LOCALE, "main.ratings", $step); 2764 2736 2765 2737 $localestrings = array(); … … 2801 2773 $localestrings['551'] = "Please specify a password."; 2802 2774 $localestrings['552'] = "Please specify an email address."; 2803 load_localestrings($localestrings, "main.register");2775 load_localestrings($localestrings, LP_LOCALE, "main.register", $step); 2804 2776 2805 2777 $localestrings = array(); … … 2874 2846 $localestrings['480']['7']['0'] = "\" \""; 2875 2847 $localestrings['480']['7']['1'] = "Double quotes at the beginning and end of a phrase, matches only rows that contain the complete phrase, as it was typed."; 2876 load_localestrings($localestrings, "main.search");2848 load_localestrings($localestrings, LP_LOCALE, "main.search", $step); 2877 2849 2878 2850 $localestrings = array(); … … 2985 2957 $localestrings['580'] = "Setup is complete, ExiteCMS is now ready for use.<br>\n<a href='index.php'>Click here</a> to go to your ExiteCMS powered site.<br>\n<b>Note:</b> you should delete setup.php from your server<br>\nand chmod your config.php back to 644 for security purposes.<br><br>\nThank you for choosing ExiteCMS."; 2986 2958 $localestrings['title'] = "ExiteCMS Setup"; 2987 load_localestrings($localestrings, "main.setup");2959 load_localestrings($localestrings, LP_LOCALE, "main.setup", $step); 2988 2960 2989 2961 $localestrings = array(); … … 3046 3018 $localestrings['u061'] = "View all posts of this member"; 3047 3019 $localestrings['u901'] = "Full Name"; 3048 load_localestrings($localestrings, "main.user_fields");3020 load_localestrings($localestrings, LP_LOCALE, "main.user_fields", $step); 3049 3021 return ""; 3022 } 3023 3024 /*---------------------------------------------------+ 3025 | start of the language pack load code | 3026 +----------------------------------------------------*/ 3027 if (!defined('CMS_SETUP')) require_once dirname(__FILE__)."/../../includes/core_functions.php"; 3028 3029 define('LP_LOCALE', "en"); 3030 define('LP_LANGUAGE', "English"); 3031 define('LP_LOCALES', "en_US|en_GB|english|eng"); 3032 define('LP_CHARSET', "iso-8859-1"); 3033 define('LP_VERSION', "7.00"); 3034 define('LP_DATE', "1196416846"); 3035 3036 /*---------------------------------------------------+ 3037 | local functions | 3038 +----------------------------------------------------*/ 3039 if (!function_exists('load_localestrings')) { 3040 function load_localestrings($localestrings, $locales_code, $locales_name, $step="") { 3041 global $db_prefix; 3042 3043 // if this is an upgrade, remove the old locale strings first 3044 if ($step == "upgrade") { 3045 $result = dbquery("DELETE FROM ".$db_prefix."locales WHERE locales_code = '$locales_code' AND locales_name = '$locales_name'"); 3046 } 3047 3048 // proces the imported locale strings 3049 foreach ($localestrings as $key => $value) { 3050 if (is_array($value)) { 3051 $value = "#ARRAY#\n".serialize($value); 3052 } 3053 $result = dbquery("INSERT INTO ".$db_prefix."locales (locales_code, locales_name, locales_key, locales_value, locales_datestamp) VALUES ('$locales_code', '$locales_name', '".mysql_escape_string($key)."', '".mysql_escape_string($value)."', '".time()."')"); 3054 } 3055 return true; 3056 } 3050 3057 } 3051 3058 … … 3054 3061 +----------------------------------------------------*/ 3055 3062 3063 // when not in CLI mode, check the users rights, and load the locale strings 3064 if (!CMS_CLI) { 3065 // check for the proper admin access rights 3066 if (!checkrights("T") || !defined("iAUTH") || $aid != iAUTH) { 3067 fallback(ADMIN."index.php"); 3068 } 3069 // load the locale for this module 3070 locale_load("admin.main"); 3071 } 3056 3072 3057 3073 if (defined('CMS_SETUP') && !defined('CMS_SETUP_LOAD')) { … … 3097 3113 // install the language pack 3098 3114 if ($step == "install" || $step == "upgrade") { 3099 if ($error = install_language_pack()) { 3115 if ($step == "install") { 3116 $result = dbquery("INSERT INTO ".$db_prefix."locale (locale_code, locale_name, locale_locale, locale_charset, locale_active) VALUES (LP_LOCALE, 'LP_LANGUAGE, LP_LOCALES, LP_CHARSET, 1)"); 3117 } 3118 if ($error = install_language_pack($step)) { 3100 3119 if (!CMS_CLI) $variables['message'] .= sprintf($locale['308'],LP_LOCALE, LP_LANGUAGE)."<br /><br />".$error; 3101 3120 } else {
Note: See TracChangeset
for help on using the changeset viewer.
