]> git.joonet.de Git - adminer.git/commitdiff
Export table header
authorJakub Vrana <jakub@vrana.cz>
Wed, 9 Mar 2011 12:11:21 +0000 (13:11 +0100)
committerJakub Vrana <jakub@vrana.cz>
Thu, 10 Mar 2011 08:51:46 +0000 (09:51 +0100)
editor/include/adminer.inc.php

index 668f9ba8bbad7eeb4321407e49f890a6b2e0d223..775725c6196a95e99e0936e576aba131bd885a6a 100644 (file)
@@ -466,6 +466,10 @@ ORDER BY ORDINAL_POSITION", null, "") as $row) { //! requires MySQL 5
                $result = $connection->query($query, 1); // 1 - MYSQLI_USE_RESULT
                if ($result) {
                        while ($row = $result->fetch_assoc()) {
+                               if ($style == "table") {
+                                       dump_csv(array_keys($row));
+                                       $style = "INSERT";
+                               }
                                dump_csv($row);
                        }
                }