[geeklog-cvs] Geeklog-1.x/public_html/admin/install index.php, 1.13, 1.14

Matthew West mwest at qs1489.pair.com
Thu Sep 6 02:48:54 EDT 2007


Update of /cvsroot/geeklog/Geeklog-1.x/public_html/admin/install
In directory qs1489.pair.com:/tmp/cvs-serv92183/Geeklog-1.x/public_html/admin/install

Modified Files:
	index.php 
Log Message:
Changed log directory permissions warning, fixed language bug when db-config.php is not in GL's root directory, added <?> help links on form page, cleaned up localization

Index: index.php
===================================================================
RCS file: /cvsroot/geeklog/Geeklog-1.x/public_html/admin/install/index.php,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -d -r1.13 -r1.14
*** index.php	3 Sep 2007 02:25:19 -0000	1.13
--- index.php	6 Sep 2007 06:48:52 -0000	1.14
***************
*** 5,9 ****
  // | Geeklog 1.4                                                               |
  // +---------------------------------------------------------------------------+
! // | install.php                                                               |
  // |                                                                           |
  // | Geeklog installation script.                                              |
--- 5,9 ----
  // | Geeklog 1.4                                                               |
  // +---------------------------------------------------------------------------+
! // | index.php                                                                 |
  // |                                                                           |
  // | Geeklog installation script.                                              |
***************
*** 180,201 ****
                  <input type="hidden" name="dbconfig_path" value="' . $dbconfig_path . '" />
  
!                 <p><label>' . $LANG_INSTALL[32] . '</label> <input type="text" name="site_name" value="' . $site_name . '" size="25" /></p>
!                 <p><label>' . $LANG_INSTALL[33] . '</label> <input type="text" name="site_slogan" value="' . $site_slogan . '" size="25" /></p><br />
!                 <p><label>' . $LANG_INSTALL[34] . '</label> <select name="db_type">
                      <option value="mysql"' . $mysql_selected . '>' . $LANG_INSTALL[35] . '</option>
                      ' . ($install_type == 'install' ? '<option value="mysql-innodb"' . $msyql_innodb_selected . '>' . $LANG_INSTALL[36] . '</option>' : '') . '
                      <option value="mssql"' . $mssql_selected . '>' . $LANG_INSTALL[37] . '</option></select> ' . $innodbnote . '</p>
!                 <p><label>' . $LANG_INSTALL[39] . '</label> <input type="text" name="db_host" value="'. $db_host .'" size="10" /></p>
!                 <p><label>' . $LANG_INSTALL[40] . '</label> <input type="text" name="db_name" value="'. $db_name . '" size="10" /></p>
!                 <p><label>' . $LANG_INSTALL[41] . '</label> <input type="text" name="db_user" value="' . $db_user . '" size="10" /></p>
!                 <p><label>' . $LANG_INSTALL[42] . '</label> <input type="password" name="db_pass" value="' . $db_pass . '" size="10" /></p>
!                 <p><label>' . $LANG_INSTALL[43] . '</label> <input type="text" name="db_prefix" value="' . $db_prefix . '" size="10" /></p>
  
                  <br />
                  <h2>' . $LANG_INSTALL[44] . '</h2>
!                 <p><label>' . $LANG_INSTALL[45] . '</label> <input type="text" name="site_url" value="' . $site_url . '" size="30" />    ' . $LANG_INSTALL[46] . '</p>
!                 <p><label>' . $LANG_INSTALL[47] . '</label> <input type="text" name="site_admin_url" value="' . $site_admin_url . '" size="30" />    ' . $LANG_INSTALL[46] . '</p>
!                 <p><label>' . $LANG_INSTALL[48] . '</label> <input type="text" name="site_mail" value="' . $site_mail . '" size="30" /></p>
!                 <p><label>' . $LANG_INSTALL[49] . '</label> <input type="text" name="noreply_mail" value="' . $noreply_mail . '" size="30" /></p>
  
                  <br />
--- 180,201 ----
                  <input type="hidden" name="dbconfig_path" value="' . $dbconfig_path . '" />
  
!                 <p><label>' . $LANG_INSTALL[32] . ' ' . INST_helpLink('site_name') . '</label> <input type="text" name="site_name" value="' . $site_name . '" size="25" /></p>
!                 <p><label>' . $LANG_INSTALL[33] . ' ' . INST_helpLink('') . '</label> <input type="text" name="site_slogan" value="' . $site_slogan . '" size="25" /></p><br />
!                 <p><label>' . $LANG_INSTALL[34] . ' ' . INST_helpLink('') . '</label> <select name="db_type">
                      <option value="mysql"' . $mysql_selected . '>' . $LANG_INSTALL[35] . '</option>
                      ' . ($install_type == 'install' ? '<option value="mysql-innodb"' . $msyql_innodb_selected . '>' . $LANG_INSTALL[36] . '</option>' : '') . '
                      <option value="mssql"' . $mssql_selected . '>' . $LANG_INSTALL[37] . '</option></select> ' . $innodbnote . '</p>
!                 <p><label>' . $LANG_INSTALL[39] . ' ' . INST_helpLink('') . '</label> <input type="text" name="db_host" value="'. $db_host .'" size="10" /></p>
!                 <p><label>' . $LANG_INSTALL[40] . ' ' . INST_helpLink('') . '</label> <input type="text" name="db_name" value="'. $db_name . '" size="10" /></p>
!                 <p><label>' . $LANG_INSTALL[41] . ' ' . INST_helpLink('') . '</label> <input type="text" name="db_user" value="' . $db_user . '" size="10" /></p>
!                 <p><label>' . $LANG_INSTALL[42] . ' ' . INST_helpLink('') . '</label> <input type="password" name="db_pass" value="' . $db_pass . '" size="10" /></p>
!                 <p><label>' . $LANG_INSTALL[43] . ' ' . INST_helpLink('') . '</label> <input type="text" name="db_prefix" value="' . $db_prefix . '" size="10" /></p>
  
                  <br />
                  <h2>' . $LANG_INSTALL[44] . '</h2>
!                 <p><label>' . $LANG_INSTALL[45] . ' ' . INST_helpLink('') . '</label> <input type="text" name="site_url" value="' . $site_url . '" size="30" />    ' . $LANG_INSTALL[46] . '</p>
!                 <p><label>' . $LANG_INSTALL[47] . ' ' . INST_helpLink('') . '</label> <input type="text" name="site_admin_url" value="' . $site_admin_url . '" size="30" />    ' . $LANG_INSTALL[46] . '</p>
!                 <p><label>' . $LANG_INSTALL[48] . ' ' . INST_helpLink('') . '</label> <input type="text" name="site_mail" value="' . $site_mail . '" size="30" /></p>
!                 <p><label>' . $LANG_INSTALL[49] . ' ' . INST_helpLink('') . '</label> <input type="text" name="noreply_mail" value="' . $noreply_mail . '" size="30" /></p>
  
                  <br />
***************
*** 493,497 ****
                              $config->set('rdf_file', $html_path . 'backend/geeklog.rss');
                              $config->set('path_pear', $_CONF['path_system'] . 'pear/');
- 
                              $config->set('default_photo', urldecode($site_url) . '/default.jpg');
  
--- 493,496 ----
***************
*** 551,558 ****
                          $config->set('site_mail', urldecode($site_mail));
                          $config->set('noreply_mail', urldecode($noreply_mail));
- 
                          $config->set('default_photo', urldecode($site_url) . '/default.jpg');
  
- 
                          // Great, installation is complete, redirect to success page
                          header('Location: success.php?type=upgrade&language=' . $language);
--- 550,555 ----
***************
*** 606,612 ****
          <div class="install-path-container-outer">
              <div class="install-path-container-inner">
!                 <h2>' . $LANG_INSTALL[101] . '</h2>
  
!                 <p>' . $LANG_INSTALL[102] . '</p>
  
                  <br />
--- 603,609 ----
          <div class="install-path-container-outer">
              <div class="install-path-container-inner">
!                 <h2>' . $LANG_INSTALL[81] . '</h2>
  
!                 <p>' . $LANG_INSTALL[82] . '</p>
  
                  <br />
***************
*** 671,674 ****
--- 668,685 ----
  
  /**
+  * Returns the HTML form to return the user's inputted data to the
+  * previous page.
+  *
+  * @return  string  HTML form code.
+  *
+  */
+ function INST_helpLink($var)
+ {
+     global $language;
+     return '(<a href="help.php?language=' . $language . '#' . $var . '" target="_blank">?</a>)';
+ }
+ 
+ 
+ /**
   * Get the current installed version of Geeklog
   *
***************
*** 1344,1348 ****
      <div class="header-navigation-container">
          <div class="header-navigation-line">
!             <a href="' . $LANG_INSTALL[107] . '" class="header-navigation">' . $LANG_INSTALL[1] . '</a>   
          </div>
      </div>
--- 1355,1359 ----
      <div class="header-navigation-container">
          <div class="header-navigation-line">
!             <a href="' . $LANG_INSTALL[87] . '" class="header-navigation">' . $LANG_INSTALL[1] . '</a>   
          </div>
      </div>
***************
*** 1360,1364 ****
      $display .='<form action="index.php" method="post">' . LB;
  
!     $_PATH = array('db-config', 'public_html');
      if (isset($_GET['mode']) || isset($_POST['mode'])) {
          $value = (isset($_POST['mode'])) ? $_POST['mode'] : $_GET['mode'];
--- 1371,1375 ----
      $display .='<form action="index.php" method="post">' . LB;
  
!     $_PATH = array('dbconfig', 'public_html');
      if (isset($_GET['mode']) || isset($_POST['mode'])) {
          $value = (isset($_POST['mode'])) ? $_POST['mode'] : $_GET['mode'];
***************
*** 1372,1376 ****
      }
  
!     $display .= $LANG_INSTALL[106] . ':  <select name="language">' . LB;
  
      foreach (glob('language/*.php') as $filename) {
--- 1383,1387 ----
      }
  
!     $display .= $LANG_INSTALL[86] . ':  <select name="language">' . LB;
  
      foreach (glob('language/*.php') as $filename) {
***************
*** 1380,1384 ****
  
      $display .= '</select>
!                     <input type="submit" value="' . $LANG_INSTALL[100] . '" />';
  }
  $display .= '
--- 1391,1395 ----
  
      $display .= '</select>
!                     <input type="submit" value="' . $LANG_INSTALL[80] . '" />';
  }
  $display .= '
***************
*** 1472,1477 ****
          // we want to make sure it's valid and exists before we continue and create problems.
          if (!file_exists($_PATH['db-config.php'])) {
!             $display .= '<h2>' . $LANG_INSTALL[103] . '</h2>'
!                     . $LANG_INSTALL[104] . $_PATH['db-config.php'] . $LANG_INSTALL[105]
                      . '<br /><br />
                        <div style="margin-left: auto; margin-right: auto; width: 1px">
--- 1483,1488 ----
          // we want to make sure it's valid and exists before we continue and create problems.
          if (!file_exists($_PATH['db-config.php'])) {
!             $display .= '<h2>' . $LANG_INSTALL[83] . '</h2>'
!                     . $LANG_INSTALL[84] . $_PATH['db-config.php'] . $LANG_INSTALL[85]
                      . '<br /><br />
                        <div style="margin-left: auto; margin-right: auto; width: 1px">
***************
*** 1597,1601 ****
                  $_PERMS['error.log']    = sprintf("%3o", @fileperms($log_path) & 0775);
                  $display_permissions    .= '<p><label class="file-permission-list"><code>' . $log_path . '</code></label><span class="error">'
!                                         . $LANG_INSTALL[14] . ' 775</span> (' . $LANG_INSTALL[13] . ' '
                                          . ($_PERMS['error.log'] == 0 ? $LANG_INSTALL[22] : $_PERMS['error.log']) . ')</p>' . LB ;
                  $failed++;
--- 1608,1612 ----
                  $_PERMS['error.log']    = sprintf("%3o", @fileperms($log_path) & 0775);
                  $display_permissions    .= '<p><label class="file-permission-list"><code>' . $log_path . '</code></label><span class="error">'
!                                         . $LANG_INSTALL[88] . ' 777</span> (' . $LANG_INSTALL[13] . ' '
                                          . ($_PERMS['error.log'] == 0 ? $LANG_INSTALL[22] : $_PERMS['error.log']) . ')</p>' . LB ;
                  $failed++;




More information about the geeklog-cvs mailing list