[Phpmyadmin-git] [SCM] phpMyAdmin branch, master, updated. RELEASE_3_4_3_1-11168-g73bb930

Michal Čihař nijel at users.sourceforge.net
Thu Jul 21 14:17:37 CEST 2011


The branch, master has been updated
       via  73bb9302b6dec3befea195cfdd9c95614281a639 (commit)
       via  beb73226c421eed473a2cc06b0d3760dafd30ae1 (commit)
       via  a8d8e0c89a6dcfee2b904220d12e0688c4e7a46e (commit)
       via  abc7e01cf07d59f12d93875162005b6cdcc492f1 (commit)
      from  7dad0213b1f965abc5d1641f6bd72c9aaf4ac2b7 (commit)


- Log -----------------------------------------------------------------
commit 73bb9302b6dec3befea195cfdd9c95614281a639
Author: Michal Čihař <mcihar at suse.cz>
Date:   Thu Jul 21 14:17:51 2011 +0200

    Minimize need for escaping by using single quotes

commit beb73226c421eed473a2cc06b0d3760dafd30ae1
Author: Michal Čihař <mcihar at suse.cz>
Date:   Thu Jul 21 14:15:35 2011 +0200

    Minor fixes in coding style

commit a8d8e0c89a6dcfee2b904220d12e0688c4e7a46e
Author: Michal Čihař <mcihar at suse.cz>
Date:   Thu Jul 21 14:13:24 2011 +0200

    Add file description

commit abc7e01cf07d59f12d93875162005b6cdcc492f1
Author: Michal Čihař <mcihar at suse.cz>
Date:   Thu Jul 21 14:11:55 2011 +0200

    Minor fixes in coding style

-----------------------------------------------------------------------

Summary of changes:
 libraries/Config.class.php   |   12 +++++++-----
 libraries/export/codegen.php |   17 ++++++++---------
 2 files changed, 15 insertions(+), 14 deletions(-)

diff --git a/libraries/Config.class.php b/libraries/Config.class.php
index 942ee9e..58ea577 100644
--- a/libraries/Config.class.php
+++ b/libraries/Config.class.php
@@ -1,7 +1,7 @@
 <?php
 /* vim: set expandtab sw=4 ts=4 sts=4: */
 /**
- *
+ * Configuration handling.
  *
  * @package phpMyAdmin
  */
@@ -359,7 +359,7 @@ class PMA_Config
 
         if ($eval_result === false) {
             $this->error_config_file = true;
-        } else  {
+        } else {
             $this->error_config_file = false;
             $this->source_mtime = filemtime($this->getSource());
         }
@@ -692,7 +692,7 @@ class PMA_Config
             $this->get('user_preferences_mtime') +
             $_SESSION['PMA_Theme']->mtime_info +
             $_SESSION['PMA_Theme']->filesize_info)
-            . (isset($_SESSION['tmp_user_values']['custom_color']) ? substr($_SESSION['tmp_user_values']['custom_color'],1,6) : '');
+            . (isset($_SESSION['tmp_user_values']['custom_color']) ? substr($_SESSION['tmp_user_values']['custom_color'], 1, 6) : '');
     }
 
     /**
@@ -975,7 +975,7 @@ class PMA_Config
         // At first we try to parse REQUEST_URI, it might contain full URL,
         if (PMA_getenv('REQUEST_URI')) {
             $url = @parse_url(PMA_getenv('REQUEST_URI')); // produces E_WARNING if it cannot get parsed, e.g. '/foobar:/'
-            if($url === false) {
+            if ($url === false) {
                 $url = array();
             }
         }
@@ -1068,7 +1068,9 @@ class PMA_Config
     /**
      * @todo finish
      */
-    function save() {}
+    function save()
+    {
+    }
 
     /**
      * returns options for font size selection
diff --git a/libraries/export/codegen.php b/libraries/export/codegen.php
index 5ee114d..bc0dada 100644
--- a/libraries/export/codegen.php
+++ b/libraries/export/codegen.php
@@ -243,8 +243,7 @@ class TableProperty
     {
         $lines=array();
         $result=PMA_DBI_query(sprintf("DESC %s.%s", PMA_backquote($db), PMA_backquote($table)));
-        if ($result)
-        {
+        if ($result) {
             $tableProperties=array();
             while ($row = PMA_DBI_fetch_row($result))
                 $tableProperties[] = new TableProperty($row);
@@ -289,17 +288,17 @@ class TableProperty
     function handleNHibernateXMLBody($db, $table, $crlf)
     {
         $lines=array();
-        $lines[] = "<?xml version=\"1.0\" encoding=\"utf-8\" ?>";
-        $lines[] = "<hibernate-mapping xmlns=\"urn:nhibernate-mapping-2.2\" namespace=\"".cgMakeIdentifier($db)."\" assembly=\"".cgMakeIdentifier($db)."\">";
-        $lines[] = "    <class name=\"".cgMakeIdentifier($table)."\" table=\"".cgMakeIdentifier($table)."\">";
+        $lines[] = '<?xml version="1.0" encoding="utf-8" ?' . '>';
+        $lines[] = '<hibernate-mapping xmlns="urn:nhibernate-mapping-2.2" '
+            . 'namespace="' . cgMakeIdentifier($db) . '" '
+            . 'assembly="' . cgMakeIdentifier($db) . '">';
+        $lines[] = '    <class name="' . cgMakeIdentifier($table) . '" table="' . cgMakeIdentifier($table) . '">';
         $result = PMA_DBI_query(sprintf("DESC %s.%s", PMA_backquote($db), PMA_backquote($table)));
-        if ($result)
-        {
+        if ($result) {
             $tableProperties = array();
             while ($row = PMA_DBI_fetch_row($result))
                 $tableProperties[] = new TableProperty($row);
-            foreach ($tableProperties as $tablePropertie)
-            {
+            foreach ($tableProperties as $tablePropertie) {
                 if ($tablePropertie->isPK())
                     $lines[] = $tablePropertie->formatXml("        <id name=\"#ucfirstName#\" type=\"#dotNetObjectType#\" unsaved-value=\"0\">\n            <column name=\"#name#\" sql-type=\"#type#\" not-null=\"#notNull#\" unique=\"#unique#\" index=\"PRIMARY\"/>\n            <generator class=\"native\" />\n        </id>");
                 else


hooks/post-receive
-- 
phpMyAdmin




More information about the Git mailing list