[geeklog-cvs] geeklog: Moved hard-coded text strings to the language file

geeklog-cvs at lists.geeklog.net geeklog-cvs at lists.geeklog.net
Mon Jan 5 05:07:07 EST 2009


details:   http://project.geeklog.net/cgi-bin/hgweb.cgi/rev/9bd8b2905fe6
changeset: 6628:9bd8b2905fe6
user:      Dirk Haun <dirk at haun-online.de>
date:      Thu Jan 01 16:59:31 2009 +0100
description:
Moved hard-coded text strings to the language file

diffstat:

3 files changed, 32 insertions(+), 16 deletions(-)
public_html/admin/install/index.php            |   30 ++++++++++++++----------
public_html/admin/install/language/english.php |    7 ++++-
public_html/admin/install/language/german.php  |   11 ++++++--

diffs (151 lines):

diff -r f6f7ccea3966 -r 9bd8b2905fe6 public_html/admin/install/index.php
--- a/public_html/admin/install/index.php	Thu Jan 01 16:12:27 2009 +0100
+++ b/public_html/admin/install/index.php	Thu Jan 01 16:59:31 2009 +0100
@@ -73,7 +73,7 @@
             }
         }
 
-        $display .= '<h1 class="heading">' . 'Step' . ' ' . $_REQUEST['display_step'] . ' - Enter configuration information</h1>' . LB;
+        $display .= '<h1 class="heading">' . $LANG_INSTALL[101] . ' ' . $_REQUEST['display_step'] . ' - ' . $LANG_INSTALL[102] . '</h1>' . LB;
 
 
         // Set all the form values either with their defaults or with received POST data.
@@ -186,7 +186,7 @@
 
         $display .='<br' . XHTML . '>
             <input type="submit" name="submit" class="submit" value="' . $buttontext . ' >>"' . XHTML . '>
-            <input type="submit" name="install_plugins" class="submit" value="' . $buttontext . ' and configure additional plugins' . ' >>"' . XHTML . '>
+            <input type="submit" name="install_plugins" class="submit" value="' . $buttontext . ' ' . $LANG_INSTALL[103] . ' >>"' . XHTML . '>
             </form>' . LB;
 
         break;
@@ -217,8 +217,8 @@
         // Check if $site_admin_url is correct
         if (!INST_urlExists($site_admin_url)) {
 
-            $display .= '<h2>' . 'Incorrect Admin Directory Path' . '</h2><p>'
-                     . 'Sorry, but the admin directory path you entered does not appear to be correct. Please go back and try again.' . '</p>'
+            $display .= '<h2>' . $LANG_INSTALL[104] . '</h2><p>'
+                     . $LANG_INSTALL[105] . '</p>'
                      . INST_showReturnFormData($_POST) . LB;
 
         // Check if we can connect to the database
@@ -232,20 +232,24 @@
         } else if (INST_mysqlOutOfDate($DB)) { 
 
             $display .= '<h1>' . $LANG_INSTALL[51] . '</h1>' . LB;
-            $display .= '<p>' . $LANG_INSTALL[52] . $myv[0] . '.' . $myv[1] . '.' . $myv[2] . $LANG_INSTALL[53] . '</p>' . LB;
+            $display .= '<p>' . $LANG_INSTALL[52]
+                     . $myv[0] . '.' . $myv[1] . '.' . $myv[2]
+                     . $LANG_INSTALL[53] . '</p>' . LB;
 
         // Check if database doesn't exist
         } else if (!INST_dbExists($DB)) {
 
-            $display .= '<h2>' . $LANG_INSTALL[56] . '</h2>
-                <p>' . $LANG_INSTALL[57] . '</p>' . INST_showReturnFormData($_POST) . LB;
+            $display .= '<h2>' . $LANG_INSTALL[56] . '</h2><p>'
+                     . $LANG_INSTALL[57] . '</p>'
+                     . INST_showReturnFormData($_POST) . LB;
 
         } else {
 
             // Write the database info to db-config.php
             if (!INST_writeConfig($dbconfig_path, $DB)) {
 
-                exit($LANG_INSTALL[26] . ' ' . $dbconfig_path . $LANG_INSTALL[58]);
+                exit($LANG_INSTALL[26] . ' ' . $dbconfig_path
+                     . $LANG_INSTALL[58]);
 
             }
 
@@ -261,7 +265,9 @@
             require $dbconfig_path;
             require_once $siteconfig_path;
             require_once $_CONF['path_system'] . 'lib-database.php';
-            $req_string = 'index.php?mode=' . $install_type . '&step=3&dbconfig_path=' . $dbconfig_path
+
+            $req_string = 'index.php?mode=' . $install_type
+                        . '&step=3&dbconfig_path=' . $dbconfig_path
                         . '&install_plugins=' . $install_plugins
                         . '&language=' . $language
                         . '&site_name=' . urlencode($site_name)
@@ -357,7 +363,7 @@
                         }
                         $display .= '</select></p>
                             <br' . XHTML . '>
-                            <input type="submit" name="submit" class="submit" value="Upgrade >>"' . XHTML . '>
+                            <input type="submit" name="submit" class="submit" value="' . $LANG_INSTALL[25] . ' >>"' . XHTML . '>
                             </form>' . LB;
 
                         $curv = $old_versions[count($old_versions) - 1];
@@ -1104,7 +1110,7 @@
             if ($num_wrong) {
                 // If any files have incorrect permissions.
 
-                $display .= INST_printTab(2) . '<h1 class="heading">' . 'Step' . ' ' . $display_step . ' - ' . $LANG_INSTALL[97] . '</h1>' . LB;
+                $display .= INST_printTab(2) . '<h1 class="heading">' . $LANG_INSTALL[101] . ' ' . $display_step . ' - ' . $LANG_INSTALL[97] . '</h1>' . LB;
                 $display_step++;
 
                 if (isset($_GET['install_type'])) {
@@ -1162,7 +1168,7 @@
 
             // Show the "Select your installation method" buttons
             $upgr_class = ($LANG_DIRECTION == 'rtl') ? 'upgrade-rtl' : 'upgrade' ;
-            $display .= INST_printTab(2) . '<h1 class="heading">' . 'Step' . ' ' . $display_step . ' - ' . $LANG_INSTALL[23] . '</h1>' . LB
+            $display .= INST_printTab(2) . '<h1 class="heading">' . $LANG_INSTALL[101] . ' ' . $display_step . ' - ' . $LANG_INSTALL[23] . '</h1>' . LB
                 . INST_printTab(3) . '<p><form action="index.php" method="GET">' . LB
                 . INST_printTab(3) . '<input type="hidden" name="dbconfig_path" value="' . $dbconfig_path . '"' . XHTML . '>' . LB
                 . INST_printTab(3) . '<input type="hidden" name="mode" value="' . $mode . '"' . XHTML . '>' . LB
diff -r f6f7ccea3966 -r 9bd8b2905fe6 public_html/admin/install/language/english.php
--- a/public_html/admin/install/language/english.php	Thu Jan 01 16:12:27 2009 +0100
+++ b/public_html/admin/install/language/english.php	Thu Jan 01 16:59:31 2009 +0100
@@ -149,7 +149,12 @@
     97 => 'Set File Permissions',
     98 => 'Advanced Users',
     99 => 'If you have command line (SSH) access to your web server then you can simple copy and paste the following command into your shell:',
-    100 => 'Invalid mode specified'
+    100 => 'Invalid mode specified',
+    101 => 'Step',
+    102 => 'Enter configuration information',
+    103 => 'and configure additional plugins',
+    104 => 'Incorrect Admin Directory Path',
+    105 => 'Sorry, but the admin directory path you entered does not appear to be correct. Please go back and try again.'
 );
 
 // +---------------------------------------------------------------------------+
diff -r f6f7ccea3966 -r 9bd8b2905fe6 public_html/admin/install/language/german.php
--- a/public_html/admin/install/language/german.php	Thu Jan 01 16:12:27 2009 +0100
+++ b/public_html/admin/install/language/german.php	Thu Jan 01 16:59:31 2009 +0100
@@ -69,7 +69,7 @@
     17 => 'User photos are disabled. The <code>userphotos</code> directory was not tested',
     18 => 'Images in articles are disabled. The <code>articles</code> directory was not tested',
     19 => 'Geeklog setzt voraus, dass bestimmte Dateien und Verzeichnisse für den Webserver schreibbar sind. Es folgt eine Liste der Dateien und Verzeichnisse, die geändert werden müssen.',
-    20 => 'Warnung!',
+    20 => 'Warnung',
     21 => 'Geeklog und Deine Website werden nicht funktionsfähig sein, solange diese Fehler nicht korrigiert werden. Bitte nimm die notwendigen Änderungen vor, bevor Du mit der Installation fortfährst.',
     22 => 'unbekannt',
     23 => 'Bitte wähle eine Installationsmethode',
@@ -96,7 +96,7 @@
     44 => 'Optionale Einstellungen',
     45 => 'URL der Website',
     46 => '(ohne Slash am Ende)',
-    47 => 'Pfad für das "admin"-Verzeichnis',
+    47 => 'URL f. "admin"-Verzeichnis',
     48 => 'Website-Email-Adresse',
     49 => '"No Reply"-Email-Adresse',
     50 => 'Installieren',
@@ -149,7 +149,12 @@
     97 => 'Set File Permissions',
     98 => 'Advanced Users',
     99 => 'If you have command line (SSH) access to your web server then you can simple copy and paste the following command into your shell:',
-    100 => 'Invalid mode specified'
+    100 => 'Invalid mode specified',
+    101 => 'Schritt',
+    102 => 'Konfigurations-Informationen eingeben',
+    103 => 'und zusätzliche Plugins konfigurieren',
+    104 => 'Incorrect Admin Directory Path',
+    105 => 'Sorry, but the admin directory path you entered does not appear to be correct. Please go back and try again.'
 );
 
 // +---------------------------------------------------------------------------+



More information about the geeklog-cvs mailing list