From aa7957a979383d45e17a93a27e46de239a2b8401 Mon Sep 17 00:00:00 2001 From: William Desportes Date: Thu, 15 Jul 2021 18:23:58 +0200 Subject: [PATCH 1/4] Ref #16939 - Remove FAQ 6.28 and update FAQ 6.8 Signed-off-by: William Desportes --- doc/faq.rst | 59 +++++++++-------------------------------------------- 1 file changed, 10 insertions(+), 49 deletions(-) diff --git a/doc/faq.rst b/doc/faq.rst index c178390c6f..b196366f39 100644 --- a/doc/faq.rst +++ b/doc/faq.rst @@ -1571,33 +1571,15 @@ enables: drop-down list of possible values. -------------------------------------------------- First the configuration variables "relation", "table\_coords" and -"pdf\_pages" have to be filled in. Then you need to think about your -schema layout. Which tables will go on which pages? +"pdf\_pages" have to be filled in. * Select your database in the navigation panel. -* Choose "Operations" in the navigation bar at the top. -* Choose "Edit :term:`PDF` Pages" near the - bottom of the page. -* Enter a name for the first :term:`PDF` page - and click Go. If you like, you can use the "automatic layout," which - will put all your linked tables onto the new page. -* Select the name of the new page (making sure the Edit radio button is - selected) and click Go. -* Select a table from the list, enter its coordinates and click Save. - Coordinates are relative; your diagram will be automatically scaled to - fit the page. When initially placing tables on the page, just pick any - coordinates -- say, 50x50. After clicking Save, you can then use the - :ref:`wysiwyg` to position the element correctly. -* When you'd like to look at your :term:`PDF`, first be sure to click the Save - button beneath the list of tables and coordinates, to save any changes you - made there. Then scroll all the way down, select the :term:`PDF` options you - want, and click Go. -* Internet Explorer for Windows may suggest an incorrect filename when - you try to save a generated :term:`PDF`. - When saving a generated :term:`PDF`, be - sure that the filename ends in ".pdf", for example "schema.pdf". - Browsers on other operating systems, and other browsers on Windows, do - not have this problem. +* Choose ":guilabel:`Designer`" in the navigation bar at the top. +* Move the tables the way you want them. +* Choose ":guilabel:`Export schema`" in the left menu. +* The export modal will open. +* Select the type of export to :term:`PDF`, you may adjust the other settings. +* Submit the form and the file will start downloading. .. seealso:: @@ -1842,31 +1824,10 @@ name), but the following variables can be used: ``@PHPMYADMIN@`` phpMyAdmin with version -.. _wysiwyg: +.. _faq6_28: -6.28 How can I easily edit relational schema for export? --------------------------------------------------------- - -By clicking on the button 'toggle scratchboard' on the page where you -edit x/y coordinates of those elements you can activate a scratchboard -where all your elements are placed. By clicking on an element, you can -move them around in the pre-defined area and the x/y coordinates will -get updated dynamically. Likewise, when entering a new position -directly into the input field, the new position in the scratchboard -changes after your cursor leaves the input field. - -You have to click on the 'OK'-button below the tables to save the new -positions. If you want to place a new element, first add it to the -table of elements and then you can drag the new element around. - -By changing the paper size and the orientation you can change the size -of the scratchboard as well. You can do so by just changing the -dropdown field below, and the scratchboard will resize automatically, -without interfering with the current placement of the elements. - -If ever an element gets out of range you can either enlarge the paper -size or click on the 'reset' button to place all elements below each -other. +6.28 (withdrawn). +----------------- .. _faq6_29: From 8661506815909773667ea0be81105d11ece19e62 Mon Sep 17 00:00:00 2001 From: William Desportes Date: Thu, 15 Jul 2021 18:41:52 +0200 Subject: [PATCH 2/4] Update FAQ 1.20 Signed-off-by: William Desportes --- doc/faq.rst | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/doc/faq.rst b/doc/faq.rst index b196366f39..8accbc1816 100644 --- a/doc/faq.rst +++ b/doc/faq.rst @@ -244,8 +244,8 @@ phpMyAdmin tried to load the extension but failed. Usually, the problem is solved by installing a software package called "PHP-MySQL" or something similar. -There are currently two interfaces PHP provides as MySQL extensions - ``mysql`` -and ``mysqli``. The ``mysqli`` is tried first, because it's the best one. +There was two interfaces PHP provided as MySQL extensions - ``mysql`` +and ``mysqli``. The ``mysql`` interface was removed in PHP 7.0. This problem can be also caused by wrong paths in the :file:`php.ini` or using wrong :file:`php.ini`. @@ -268,10 +268,9 @@ can tell it to use specific path for this file using ``PHPIniDir`` directive: .. code-block:: apache - LoadFile "C:/php/php5ts.dll" - LoadModule php5_module "C:/php/php5apache2_2.dll" - - PHPIniDir "C:/PHP" + LoadModule php7_module "C:/php7/php7apache2_4.dll" + + PHPIniDir "C:/php7" AddType text/html .php AddHandler application/x-httpd-php .php From a36dd1126bed39a87a2ee80c973259361c5c1e80 Mon Sep 17 00:00:00 2001 From: William Desportes Date: Thu, 15 Jul 2021 21:32:56 +0200 Subject: [PATCH 3/4] Fix #17006 - Disable the URL limit for the MariaDB analyser feature Signed-off-by: William Desportes --- libraries/classes/Html/Generator.php | 22 ++++++++++++++-------- test/classes/Html/GeneratorTest.php | 24 ++++++++++++++++++++++++ 2 files changed, 38 insertions(+), 8 deletions(-) diff --git a/libraries/classes/Html/Generator.php b/libraries/classes/Html/Generator.php index 0b799a6ff3..f5de9f8d39 100644 --- a/libraries/classes/Html/Generator.php +++ b/libraries/classes/Html/Generator.php @@ -666,7 +666,8 @@ class Generator htmlspecialchars('url.php?url=' . urlencode($url)), sprintf(__('Analyze Explain at %s'), 'mariadb.org'), [], - '_blank' + '_blank', + false ) . ' ]'; } } @@ -1091,7 +1092,8 @@ class Generator $url, $message, $tag_params = [], - $target = '' + $target = '', + bool $respectUrlLengthLimit = true ): string { $url_length = strlen($url); @@ -1132,12 +1134,16 @@ class Generator } $tag_params_strings = []; - if (($url_length > $GLOBALS['cfg']['LinkLengthLimit']) - || ! $in_suhosin_limits - // Has as sql_query without a signature - || (strpos($url, 'sql_query=') !== false && strpos($url, 'sql_signature=') === false) - || strpos($url, 'view[as]=') !== false - ) { + $isDataPostFormatSupported = ($url_length > $GLOBALS['cfg']['LinkLengthLimit']) + || ! $in_suhosin_limits + // Has as sql_query without a signature, to be accepted it needs + // to be sent using POST + || ( + strpos($url, 'sql_query=') !== false + && strpos($url, 'sql_signature=') === false + ) + || strpos($url, 'view[as]=') !== false; + if ($respectUrlLengthLimit && $isDataPostFormatSupported) { $parts = explode('?', $url, 2); /* * The data-post indicates that client should do POST diff --git a/test/classes/Html/GeneratorTest.php b/test/classes/Html/GeneratorTest.php index f4b292a75d..23c7d5d30c 100644 --- a/test/classes/Html/GeneratorTest.php +++ b/test/classes/Html/GeneratorTest.php @@ -244,6 +244,30 @@ class GeneratorTest extends AbstractTestCase 1000, 'text', ], + [ + [ + 'https://mariadb.org/explain_analyzer/analyze/?client=phpMyAdmin&raw_explain=%2B---%2B', + 'text', + [], + 'target', + ], + 10, + // This is not the behavior we want for the analyser feature, next test will disable the limit + 'text', + ], + [ + [ + 'https://mariadb.org/explain_analyzer/analyze/?client=phpMyAdmin&raw_explain=%2B---%2B', + 'text', + [], + 'target', + false, + ], + 10, + 'text', + ], [ [ 'url.php?url=http://phpmyadmin.net/', From b58730c5aceb70bc423962aaaab60496c536ecd9 Mon Sep 17 00:00:00 2001 From: William Desportes Date: Thu, 15 Jul 2021 21:35:57 +0200 Subject: [PATCH 4/4] Add a ChangeLog entry for #17006 Signed-off-by: William Desportes --- ChangeLog | 1 + 1 file changed, 1 insertion(+) diff --git a/ChangeLog b/ChangeLog index 00cd286a6f..dbf8d7ac34 100644 --- a/ChangeLog +++ b/ChangeLog @@ -37,6 +37,7 @@ phpMyAdmin - ChangeLog - issue #16976 Fix wrong link when a table is moved from a database to another - issue #16985 Fix case-sensitive issue of innodb_file_format=barracuda vs innodb_file_format=Barracuda - issue Fixed duplicate quote in navigation nodes +- issue #17006 Disable the URL limit for the MariaDB analyser feature 5.1.1 (2021-06-04) - issue #13325 Fixed created procedure shows up in triggers and events and vice-versa