From 1ad37348109ce0f519a6a2d0999bc1f4f250b82e Mon Sep 17 00:00:00 2001 From: developerchan1 Date: Mon, 4 Sep 2017 09:36:13 +0000 Subject: [PATCH 1/8] Translated using Weblate (Indonesian) Currently translated at 76.2% (2445 of 3205 strings) [CI skip] --- po/id.po | 132 +++++++++++++++++-------------------------------------- 1 file changed, 40 insertions(+), 92 deletions(-) diff --git a/po/id.po b/po/id.po index 12ce3afa6a..7ab756878c 100644 --- a/po/id.po +++ b/po/id.po @@ -4,7 +4,7 @@ msgstr "" "Project-Id-Version: phpMyAdmin 4.7.4-dev\n" "Report-Msgid-Bugs-To: translators@phpmyadmin.net\n" "POT-Creation-Date: 2017-08-10 09:13-0400\n" -"PO-Revision-Date: 2017-09-04 08:16+0000\n" +"PO-Revision-Date: 2017-09-04 13:04+0000\n" "Last-Translator: developerchan1 \n" "Language-Team: Indonesian " "\n" @@ -8626,10 +8626,8 @@ msgid "Custom - display all possible options" msgstr "Kustom - menampilkan semua opsi" #: libraries/display_export.lib.php:340 -#, fuzzy -#| msgid "Databases" msgid "Databases:" -msgstr "Basis data" +msgstr "Basis data:" #: libraries/display_export.lib.php:342 libraries/navigation/Navigation.php:197 msgid "Tables:" @@ -8642,14 +8640,14 @@ msgstr "Format:" #: libraries/display_export.lib.php:378 libraries/display_import.lib.php:370 msgid "Format-specific options:" -msgstr "Opsi khusus format:" +msgstr "Opsi format-spesifik:" #: libraries/display_export.lib.php:381 msgid "" "Scroll down to fill in the options for the selected format and ignore the " "options for other formats." msgstr "" -"Gulir ke bawah untuk mengisi pilihan untuk format yang dipilih dan " +"Tarik ke bawah untuk mengisi pilihan untuk format yang dipilih dan " "mengabaikan pilihan untuk format lain." #: libraries/display_export.lib.php:391 libraries/display_import.lib.php:381 @@ -8679,7 +8677,7 @@ msgstr "Hasil:" #: libraries/display_export.lib.php:493 libraries/display_export.lib.php:528 #, php-format msgid "Save on server in the directory %s" -msgstr "Simpan ke direktori %s di server" +msgstr "Simpan ke server didalam direktori %s" #: libraries/display_export.lib.php:558 msgid "File name template:" @@ -8734,30 +8732,24 @@ msgid "View output as text" msgstr "Tampilkan hasil sebagai teks" #: libraries/display_export.lib.php:752 -#, fuzzy -#| msgid "Export views as tables" msgid "Export databases as separate files" -msgstr "Mengekspor tampilan sebagai tabel" +msgstr "Mengekspor database sebagai file terpisah" #: libraries/display_export.lib.php:754 -#, fuzzy -#| msgid "horizontal (rotated headers)" msgid "Export tables as separate files" -msgstr "horisontal (judul diputar)" +msgstr "Mengekspor tabel sebagai file terpisah" #: libraries/display_export.lib.php:784 libraries/display_export.lib.php:960 -#, fuzzy msgid "Rename exported databases/tables/columns" -msgstr "Ubah nama diekspor database / tabel / kolom" +msgstr "Ubah nama database / tabel / kolom yang diekspor" #: libraries/display_export.lib.php:809 msgid "Save output to a file" msgstr "Simpan hasil ke suatu berkas" #: libraries/display_export.lib.php:842 -#, fuzzy msgid "Skip tables larger than" -msgstr "Lewati tabel lebih besar dari" +msgstr "Lewati tabel yang lebih besar dari" #: libraries/display_export.lib.php:895 msgid "Defined aliases" @@ -8826,25 +8818,20 @@ msgstr "" "Contoh: .sql.zip" #: libraries/display_import.lib.php:224 -#, fuzzy -#| msgid "File to Import:" msgid "File to import:" -msgstr "Berkas untuk Diimpor:" +msgstr "Berkas untuk impor:" #: libraries/display_import.lib.php:234 libraries/display_import.lib.php:254 -#, fuzzy msgid "You may also drag and drop a file on any page." -msgstr "Anda juga dapat drag dan drop file pada halaman manapun." +msgstr "Anda juga dapat drag dan drop sebuah file pada halaman manapun." #: libraries/display_import.lib.php:257 msgid "File uploads are not allowed on this server." msgstr "Pengunggahan berkas tidak diizinkan di server ini." #: libraries/display_import.lib.php:284 -#, fuzzy -#| msgid "Partial Import:" msgid "Partial import:" -msgstr "Impor Parsial:" +msgstr "Impor sebagian:" #: libraries/display_import.lib.php:291 #, php-format @@ -8877,10 +8864,8 @@ msgstr "" "dari yang pertama:" #: libraries/display_import.lib.php:345 -#, fuzzy -#| msgid "Options" msgid "Other options:" -msgstr "Opsi" +msgstr "Opsi lain:" #: libraries/display_import.lib.php:483 #, fuzzy @@ -8899,10 +8884,8 @@ msgid "%s of %s" msgstr "%s dari %s" #: libraries/display_import.lib.php:490 -#, fuzzy -#| msgid "Format of imported file" msgid "Uploading your import file…" -msgstr "Format berkas impor" +msgstr "Sedang memuat file impor anda…" #: libraries/display_import.lib.php:491 #, php-format @@ -9318,15 +9301,13 @@ msgid "" msgstr "Mengubah pengaturan yang dengan mengklik sesuai \"Options\" link." #: libraries/import.lib.php:1212 -#, fuzzy msgid "Edit structure by following the \"Structure\" link." -msgstr "Mengedit struktur dengan mengikuti link \"Struktur\"." +msgstr "Edit struktur dengan mengikuti link \"Struktur\"." #: libraries/import.lib.php:1219 -#, fuzzy, php-format -#| msgid "Go to database" +#, php-format msgid "Go to database: %s" -msgstr "Tuju ke basis data" +msgstr "Menuju ke database : %s" #: libraries/import.lib.php:1225 libraries/import.lib.php:1269 #, php-format @@ -9334,10 +9315,9 @@ msgid "Edit settings for %s" msgstr "Edit pengaturan %s" #: libraries/import.lib.php:1254 -#, fuzzy, php-format -#| msgid "Go to table" +#, php-format msgid "Go to table: %s" -msgstr "Tuju ke tabel" +msgstr "Menuju ke tabel: %s" #: libraries/import.lib.php:1262 #, php-format @@ -9345,10 +9325,9 @@ msgid "Structure of %s" msgstr "Struktur %s" #: libraries/import.lib.php:1280 -#, fuzzy, php-format -#| msgid "Go to view" +#, php-format msgid "Go to view: %s" -msgstr "Tuju ke view" +msgstr "Menuju ke view: %s" #: libraries/import.lib.php:1340 #, fuzzy @@ -9387,10 +9366,8 @@ msgid "Binary" msgstr "Biner" #: libraries/insert_edit.lib.php:605 -#, fuzzy -#| msgid "Because of its length,
this column might not be editable" msgid "Because of its length,
this column might not be editable." -msgstr "Karena panjangnya,
isian ini mungkin tidak dapat diedit" +msgstr "Karena panjangnya,
kolom ini mungkin tidak dapat diedit." #: libraries/insert_edit.lib.php:1100 msgid "Binary - do not edit" @@ -9403,10 +9380,8 @@ msgid "Or" msgstr "Atau" #: libraries/insert_edit.lib.php:1237 -#, fuzzy -#| msgid "web server upload directory" msgid "web server upload directory:" -msgstr "direktori unggahan server web" +msgstr "direktori unggahan server web:" #: libraries/insert_edit.lib.php:1417 templates/table/search/input_box.phtml:46 msgid "Edit/Insert" @@ -9450,14 +9425,11 @@ msgid "Edit next row" msgstr "Edit baris berikut" #: libraries/insert_edit.lib.php:1609 -#, fuzzy -#| msgid "" -#| "Use TAB key to move from value to value, or CTRL+arrows to move anywhere" msgid "" "Use TAB key to move from value to value, or CTRL+arrows to move anywhere." msgstr "" -"Gunakan tombol TAB untuk maju dari angka ke angka atau gunakan CTRL+panah " -"untuk maju kemana saja" +"Gunakan tombol TAB untuk berpindah dari angka ke angka atau gunakan CTRL+" +"panah untuk pindah kemana saja." #: libraries/insert_edit.lib.php:1646 libraries/replication_gui.lib.php:544 #: libraries/rte/rte_routines.lib.php:1609 @@ -9534,10 +9506,8 @@ msgid "Add prefix" msgstr "Tambahkan prefiks" #: libraries/mult_submits.lib.php:446 -#, fuzzy -#| msgid "Do you really want to " msgid "Do you really want to execute the following query?" -msgstr "Benarkah Anda ingin untuk " +msgstr "Apakah anda benar-benar ingin untuk mengesekusi queri di ikuti?" #: libraries/navigation/Navigation.php:55 msgid "An error has occurred while loading the navigation display" @@ -11958,10 +11928,8 @@ msgid "Re-type" msgstr "Ketik ulang" #: libraries/replication_gui.lib.php:873 -#, fuzzy -#| msgid "Generate password" msgid "Generate password:" -msgstr "Buatkan kata sandi" +msgstr "Menghasilkan kata sandi:" #: libraries/replication_gui.lib.php:905 msgid "" @@ -11972,50 +11940,36 @@ msgstr "" "$cfg['AllowArbitraryServer'] pada konfigurasi phpMyAdmin." #: libraries/replication_gui.lib.php:914 -#, fuzzy -#| msgid "Replication status" msgid "Replication started successfully." -msgstr "Status replikasi" +msgstr "Replikasi berhasil dilakukan." #: libraries/replication_gui.lib.php:915 -#, fuzzy -#| msgid "Master replication" msgid "Error starting replication." -msgstr "Replikasi master" +msgstr "Kesalahan melakukan replikasi." #: libraries/replication_gui.lib.php:918 -#, fuzzy -#| msgid "Chart generated successfully." msgid "Replication stopped successfully." -msgstr "Sukses reload Hak Istimewa (Privileges)." +msgstr "Replikasi berhasil dihentikan." #: libraries/replication_gui.lib.php:919 -#, fuzzy -#| msgid "Master replication" msgid "Error stopping replication." -msgstr "Replikasi master" +msgstr "Kesalahan menghentikan replikasi." #: libraries/replication_gui.lib.php:922 -#, fuzzy -#| msgid "Replication status" msgid "Replication resetting successfully." -msgstr "Status replikasi" +msgstr "Replikasi berhasil diatur ulang." #: libraries/replication_gui.lib.php:923 -#, fuzzy -#| msgid "Master replication" msgid "Error resetting replication." -msgstr "Replikasi master" +msgstr "Kesalahan mensetting ulang replikasi." #: libraries/replication_gui.lib.php:926 msgid "Success." -msgstr "Sukses." +msgstr "Berhasil." #: libraries/replication_gui.lib.php:927 -#, fuzzy -#| msgid "Error" msgid "Error." -msgstr "Galat" +msgstr "Galat." #: libraries/replication_gui.lib.php:972 msgid "Unknown error" @@ -12477,9 +12431,8 @@ msgid "Export of event %s" msgstr "Ekspor event %s" #: libraries/rte/rte_words.lib.php:66 -#, fuzzy msgid "event" -msgstr "event" +msgstr "acara" #: libraries/rte/rte_words.lib.php:68 #, fuzzy @@ -12488,20 +12441,17 @@ msgid "You do not have the necessary privileges to create an event." msgstr "Anda tidak punya hak akses untuk membuat event" #: libraries/rte/rte_words.lib.php:70 -#, fuzzy, php-format -#| msgid "No event with name %1$s found in database %2$s" +#, php-format msgid "No event with name %1$s found in database %2$s." -msgstr "Event dengan nama %1$s tidak ditemukan dalam basis data %2$s" +msgstr "Tidak ada event dengan nama %1$s ditemukan dalam basis data %2$s." #: libraries/rte/rte_words.lib.php:71 msgid "There are no events to display." msgstr "Tidak ada event untuk ditampilkan." #: libraries/select_server.lib.php:44 libraries/select_server.lib.php:49 -#, fuzzy -#| msgid "Current server" msgid "Current server:" -msgstr "Server saat ini" +msgstr "Server saat ini:" #: libraries/server_common.lib.php:24 msgid "Server variables and settings" @@ -13430,10 +13380,8 @@ msgid "Clear series" msgstr "Bersihkan seri" #: libraries/server_status_monitor.lib.php:229 -#, fuzzy -#| msgid "Series in Chart:" msgid "Series in chart:" -msgstr "Seri pada Bagan:" +msgstr "Seri pada grafik:" #: libraries/server_status_monitor.lib.php:250 msgid "Start Monitor" From 56c61b7f37ab1e29ffe40c04a44aed8ddf5c293a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C4=81ris?= Date: Mon, 4 Sep 2017 12:55:53 +0000 Subject: [PATCH 2/8] Translated using Weblate (Latvian) Currently translated at 17.8% (572 of 3205 strings) [CI skip] --- po/lv.po | 64 +++++++++++++++++++++++++------------------------------- 1 file changed, 29 insertions(+), 35 deletions(-) diff --git a/po/lv.po b/po/lv.po index 51ffad1c36..3367d76df8 100644 --- a/po/lv.po +++ b/po/lv.po @@ -4,16 +4,16 @@ msgstr "" "Project-Id-Version: phpMyAdmin 4.7.4-dev\n" "Report-Msgid-Bugs-To: translators@phpmyadmin.net\n" "POT-Creation-Date: 2017-08-10 09:13-0400\n" -"PO-Revision-Date: 2017-06-14 14:29+0000\n" +"PO-Revision-Date: 2017-09-04 13:04+0000\n" "Last-Translator: Māris \n" -"Language-Team: Latvian \n" +"Language-Team: Latvian " +"\n" "Language: lv\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n != 0 ? 1 : 2;\n" -"X-Generator: Weblate 2.15-dev\n" +"X-Generator: Weblate 2.17-dev\n" #: ajax.php:16 ajax.php:33 export.php:192 schema_export.php:64 msgid "Bad type!" @@ -305,15 +305,12 @@ msgid "Database %1$s has been copied to %2$s." msgstr "Datubāze %1$s tika pārkopēta uz %2$s." #: db_operations.php:279 -#, fuzzy, php-format -#| msgid "" -#| "The phpMyAdmin configuration storage has been deactivated. To find out " -#| "why click %shere%s." +#, php-format msgid "" "The phpMyAdmin configuration storage has been deactivated. %sFind out why%s." msgstr "" -"Papildiespējas darbam ar saistītām tabulām tika izslēgtas. Lai uzzinātu " -"kāpēc, klikškiniet %sšeit%s." +"Papildiespējas darbam ar saistītām tabulām ir izslēgtas. %sNoskaidrot " +"kāpēc%s." #: db_qbe.php:126 msgid "You have to choose at least one column to display!" @@ -343,10 +340,8 @@ msgstr "" "Versija %1$s iezīmētajām tabulām tika izveidota, to atsekošana ir aktīva." #: db_tracking.php:93 -#, fuzzy -#| msgid "No databases selected." msgid "No tables selected." -msgstr "Datubāze nav izvēlēta." +msgstr "Nav izvēlēta tabula." #: db_tracking.php:150 msgid "Database Log" @@ -565,31 +560,30 @@ msgid "Bookmark %s has been created." msgstr "Grāmatzīme %s ir izveidota." #: import.php:581 -#, fuzzy, php-format -#| msgid "Import has been successfully finished, %d queries executed." +#, php-format msgid "Import has been successfully finished, %d query executed." msgid_plural "Import has been successfully finished, %d queries executed." -msgstr[0] "Importēšana veiksmīga, %d pieprasījumi izpildīti." -msgstr[1] "Importēšana veiksmīga, %d pieprasījumi izpildīti." -msgstr[2] "Importēšana veiksmīga, %d pieprasījumi izpildīti." +msgstr[0] "Importēšana veiksmīga, izpildīts %d vaicājums." +msgstr[1] "Importēšana veiksmīga, izpildīti %d vaicājumi." +msgstr[2] "Importēšana veiksmīga, izpildīti %d vaicājumi." #: import.php:612 -#, fuzzy, php-format -#| msgid "" -#| "Script timeout passed, if you want to finish import, please resubmit same " -#| "file and import will resume." +#, php-format msgid "" "Script timeout passed, if you want to finish import, please %sresubmit the " "same file%s and import will resume." msgstr "" -"Ir iestājies skripta noilgums, ja jūs vēlaties beigt importu, tad atkal " -"izvēlieties to pašu failu un importēšana turpināsies." +"Ir iestājies skripta noilgums, ja vēlaties pabeigt importu līdz galam, tad %" +"sizvēlieties vēlreiz to pašu failu%s un importēšana turpināsies." #: import.php:622 msgid "" "However on last run no data has been parsed, this usually means phpMyAdmin " "won't be able to finish this import unless you increase php time limits." msgstr "" +"Diemžēl pēdējā palaišanas reizē netika apstrādāti nekādi dati. Tas nozīmē, " +"ka phpMyAdmin nebūs spējīgs pabeigt importu, ja vien nepalielināsiet php " +"izpildes laika ierobežojumus." #: import.php:693 sql.php:163 msgid "\"DROP DATABASE\" statements are disabled." @@ -597,7 +591,7 @@ msgstr "\"DROP DATABASE\" komanda ir aizliegta." #: import_status.php:105 msgid "Could not load the progress of the import." -msgstr "" +msgstr "Neizdevās ielādēt importa progresu." #: import_status.php:114 js/messages.php:455 js/messages.php:619 #: libraries/Util.php:689 libraries/export.lib.php:518 @@ -610,6 +604,8 @@ msgid "" "You were logged out from one server, to logout completely from phpMyAdmin, " "you need to logout from all servers." msgstr "" +"Jūs atslēdzāties no viena servera. Lai atslēgtos no phpMyAdmin pilnībā, " +"jāatslēdzas no visiem serveriem." #: index.php:160 libraries/Footer.php:69 msgid "phpMyAdmin Demo Server" @@ -626,10 +622,8 @@ msgstr "" "root, debian-sys-maint un pma users tabulas. Vairāk informācijas %s." #: index.php:174 -#, fuzzy -#| msgid "General Settings" msgid "General settings" -msgstr "Galvenie uzstādījumi" +msgstr "Galvenie iestatījumi" #: index.php:204 js/messages.php:644 #: libraries/display_change_password.lib.php:47 @@ -642,10 +636,8 @@ msgid "Server connection collation" msgstr "MySQL savienojuma kārtošana" #: index.php:242 -#, fuzzy -#| msgid "Appearance Settings" msgid "Appearance settings" -msgstr "Izskata uzstādījumi" +msgstr "Izskata iestatījumi" #: index.php:275 prefs_manage.php:294 msgid "More settings" @@ -694,10 +686,8 @@ msgid "PHP extension:" msgstr "PHP paplašinājums:" #: index.php:365 -#, fuzzy -#| msgid "PHP Version" msgid "PHP version:" -msgstr "PHP Versija" +msgstr "PHP versija:" #: index.php:376 msgid "Show PHP information" @@ -733,7 +723,7 @@ msgstr "Izmaiņu saraksts" #: index.php:441 templates/server/plugins/section.phtml:12 msgid "License" -msgstr "" +msgstr "Licence" #: index.php:461 msgid "" @@ -741,6 +731,10 @@ msgid "" "multibyte charset. Without the mbstring extension phpMyAdmin is unable to " "split strings correctly and it may result in unexpected results." msgstr "" +"Netika atrasts PHP paplašinājums \"mbstring\" un izskatās, ka jūs lietojat " +"vairākbaitu rakstzīmju kopu (multibyte charset). Bez \"mbstring\" " +"paplašinājuma phpMyAdmin nebūs spējīgs pareizi sadalīt simbolu virknes un " +"tas var novest pie negaidītiem rezultātiem." #: index.php:476 msgid "" From 6adb95b4ae82686fdc198b5e4c0472060b4ce2f7 Mon Sep 17 00:00:00 2001 From: Piotr Strebski Date: Mon, 4 Sep 2017 09:01:30 +0000 Subject: [PATCH 3/8] Translated using Weblate (Polish) Currently translated at 81.0% (2598 of 3205 strings) [CI skip] --- po/pl.po | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/po/pl.po b/po/pl.po index 6ac811b270..84a121b9ab 100644 --- a/po/pl.po +++ b/po/pl.po @@ -4,17 +4,17 @@ msgstr "" "Project-Id-Version: phpMyAdmin 4.7.4-dev\n" "Report-Msgid-Bugs-To: translators@phpmyadmin.net\n" "POT-Creation-Date: 2017-08-10 09:13-0400\n" -"PO-Revision-Date: 2017-08-03 20:58+0000\n" -"Last-Translator: Marcin Wróblewski \n" -"Language-Team: Polish \n" +"PO-Revision-Date: 2017-09-04 13:04+0000\n" +"Last-Translator: Piotr Strebski \n" +"Language-Team: Polish " +"\n" "Language: pl\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 " "|| n%100>=20) ? 1 : 2;\n" -"X-Generator: Weblate 2.16-dev\n" +"X-Generator: Weblate 2.17-dev\n" #: ajax.php:16 ajax.php:33 export.php:192 schema_export.php:64 msgid "Bad type!" @@ -781,8 +781,7 @@ msgstr "" #: index.php:532 msgid "The secret passphrase in configuration (blowfish_secret) is too short." msgstr "" -"Tajna fraza kodująca (blowfish_secret) w pliku konfiguracyjnym jest za " -"krótka." +"Klucz szyfrujący (blowfish_secret) podany w konfiguracji jest zbyt krótki." #: index.php:546 msgid "" @@ -803,15 +802,16 @@ msgid "" "The phpMyAdmin configuration storage is not completely configured, some " "extended features have been deactivated. %sFind out why%s. " msgstr "" -"Przechowywania konfiguracji phpMyAdmin nie jest w pełni skonfigurowane, " -"niektóre rozszerzone funkcje zostały wyłączone. %sDowiedz się dlaczego%s. " +"Program phpMyAdmin nie ma w pełni skonfigurowanej przestrzeni do " +"przechowywania danych, niektóre rozszerzone funkcje zostały wyłączone. Aby " +"dowiedzieć się dlaczego kliknij %stutaj%s. " #: index.php:569 msgid "" "Or alternately go to 'Operations' tab of any database to set it up there." msgstr "" -"Możesz też przejść do karty 'Operacje' dowolnej bazy danych, by " -"skonfigurować tą opcję tylko dla tej bazy." +"Możesz też przejść do zakładki 'Operacje' w dowolnej bazie danych, aby tam " +"to skonfigurować." #: index.php:594 #, php-format From aa75d66eec0dca4143f36a087632260f81a9d160 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Mon, 4 Sep 2017 12:22:04 +0200 Subject: [PATCH 4/8] Remove tested propery MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Originally the code could delete PROP_COLUMN_ORDER when asking for PROP_COLUMN_VISIB. Issue #13604 Signed-off-by: Michal Čihař --- libraries/Table.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libraries/Table.php b/libraries/Table.php index 5cebd5a383..c26d439bcf 100644 --- a/libraries/Table.php +++ b/libraries/Table.php @@ -1735,7 +1735,7 @@ class Table } } // remove the property, since it no longer exists in database - $this->removeUiProp(self::PROP_SORTED_COLUMN); + $this->removeUiProp($property); return false; } @@ -1753,7 +1753,7 @@ class Table } // remove the property, since the table has been modified - $this->removeUiProp(self::PROP_COLUMN_ORDER); + $this->removeUiProp($property); return false; } From 00485eb593e94b051c5839dd03c15aeb982fc32a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Mon, 4 Sep 2017 12:28:18 +0200 Subject: [PATCH 5/8] Share code for getting column params MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Issue #13604 Signed-off-by: Michal Čihař --- libraries/DisplayResults.php | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/libraries/DisplayResults.php b/libraries/DisplayResults.php index 2d734b8961..c0cf01e838 100644 --- a/libraries/DisplayResults.php +++ b/libraries/DisplayResults.php @@ -1298,9 +1298,7 @@ class DisplayResults . ''; // Output data needed for column reordering and show/hide column - if ($this->_isSelect($analyzed_sql_results)) { - $table_headers_html .= $this->_getDataForResettingColumnOrder(); - } + $table_headers_html .= $this->_getDataForResettingColumnOrder($analyzed_sql_results); $display_params['emptypre'] = 0; $display_params['emptyafter'] = 0; @@ -1641,28 +1639,32 @@ class DisplayResults /** * Prepare data for column restoring and show/hide * + * @param array $analyzed_sql_results analyzed sql results + * * @return string $data_html html content * * @access private * * @see _getTableHeaders() */ - private function _getDataForResettingColumnOrder() + private function _getDataForResettingColumnOrder($analyzed_sql_results) { - - $data_html = ''; + if (! $this->_isSelect($analyzed_sql_results)) { + return ''; + } // generate the column order, if it is set - $pmatable = new Table($this->__get('table'), $this->__get('db')); - $col_order = $pmatable->getUiProp(Table::PROP_COLUMN_ORDER); + list($col_order, $col_visib) = $this->_getColumnParams( + $analyzed_sql_results + ); + + $data_html = ''; if ($col_order) { $data_html .= ''; } - $col_visib = $pmatable->getUiProp(Table::PROP_COLUMN_VISIB); - if ($col_visib) { $data_html .= ''; From 483324d0a96d8117d4523a2446012450225686d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Mon, 4 Sep 2017 12:56:12 +0200 Subject: [PATCH 6/8] Fixed crash on invalid ordering data MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We have to validate the data prior to use. Having just integer doesn't make them work. Fixes #13604 Signed-off-by: Michal Čihař --- ChangeLog | 1 + libraries/DisplayResults.php | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/ChangeLog b/ChangeLog index ee58b11b30..954583783a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -7,6 +7,7 @@ phpMyAdmin - ChangeLog - issue #13628 Fixed javascript error in server monitor - issue #13444 Fixed server monitor on non Linux and Windows systems - issue #13633 Reload javscript messages when changing language +- issue #13604 Fixed crash on invalid ordering data 4.7.4 (2017-08-23) - issue #13415 Remove shadow from the logo diff --git a/libraries/DisplayResults.php b/libraries/DisplayResults.php index c0cf01e838..7f8a41fe19 100644 --- a/libraries/DisplayResults.php +++ b/libraries/DisplayResults.php @@ -3397,6 +3397,16 @@ class DisplayResults if ($this->_isSelect($analyzed_sql_results)) { $pmatable = new Table($this->__get('table'), $this->__get('db')); $col_order = $pmatable->getUiProp(Table::PROP_COLUMN_ORDER); + /* Validate the value */ + if ($col_order !== false) { + $fields_cnt = $this->__get('fields_cnt'); + foreach ($col_order as $value) { + if ($value >= $fields_cnt) { + $this->removeUiProp(Table::PROP_COLUMN_ORDER); + $fields_cnt = false; + } + } + } $col_visib = $pmatable->getUiProp(Table::PROP_COLUMN_VISIB); } else { $col_order = false; From 47f7ba159e6f7e3e1ac680f37a04df63fb77b06a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Mon, 4 Sep 2017 14:35:15 +0200 Subject: [PATCH 7/8] Fixed error when browsing non SELECT results MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We can not assume that the analyzer will work on our query. Fixes #13639 Signed-off-by: Michal Čihař --- ChangeLog | 1 + libraries/DisplayResults.php | 14 +++++++++----- libraries/sql.lib.php | 3 +++ 3 files changed, 13 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index 954583783a..59fb5b47cb 100644 --- a/ChangeLog +++ b/ChangeLog @@ -8,6 +8,7 @@ phpMyAdmin - ChangeLog - issue #13444 Fixed server monitor on non Linux and Windows systems - issue #13633 Reload javscript messages when changing language - issue #13604 Fixed crash on invalid ordering data +- issue #13639 Fixed error when browsing non SELECT results 4.7.4 (2017-08-23) - issue #13415 Remove shadow from the logo diff --git a/libraries/DisplayResults.php b/libraries/DisplayResults.php index 7f8a41fe19..2fd5d1bcff 100644 --- a/libraries/DisplayResults.php +++ b/libraries/DisplayResults.php @@ -4257,7 +4257,11 @@ class DisplayResults * The statement this table is built for. * @var \PhpMyAdmin\SqlParser\Statements\SelectStatement */ - $statement = $analyzed_sql_results['statement']; + if (isset($analyzed_sql_results['statement'])) { + $statement = $analyzed_sql_results['statement']; + } else { + $statement = null; + } $table_html = ''; // Following variable are needed for use in isset/empty or @@ -4313,7 +4317,7 @@ class DisplayResults $sort_expression_nodirection = array(); $sort_direction = array(); - if (!empty($statement->order)) { + if (!is_null($statement) && !empty($statement->order)) { foreach ($statement->order as $o) { $sort_expression[] = $o->expr->expr . ' ' . $o->type; $sort_expression_nodirection[] = $o->expr->expr; @@ -4391,7 +4395,7 @@ class DisplayResults $sort_by_key_html = $unsorted_sql_query = ''; } - if (($displayParts['nav_bar'] == '1') && (empty($statement->limit))) { + if (($displayParts['nav_bar'] == '1') && !is_null($statement) && (empty($statement->limit))) { $table_html .= $this->_getPlacedTableNavigations( $pos_next, $pos_prev, self::PLACE_TOP_DIRECTION_DROPDOWN, $is_innodb, $sort_by_key_html @@ -4405,7 +4409,7 @@ class DisplayResults $map = array(); $target = array(); - if (!empty($statement->from)) { + if (!is_null($statement) && !empty($statement->from)) { foreach ($statement->from as $field) { if (!empty($field->table)) { $target[] = $field->table; @@ -4474,7 +4478,7 @@ class DisplayResults } // 5. ----- Get the navigation bar at the bottom if required ----- - if (($displayParts['nav_bar'] == '1') && empty($statement->limit)) { + if (($displayParts['nav_bar'] == '1') && !is_null($statement) && empty($statement->limit)) { $table_html .= $this->_getPlacedTableNavigations( $pos_next, $pos_prev, self::PLACE_BOTTOM_DIRECTION_DROPDOWN, $is_innodb, $sort_by_key_html diff --git a/libraries/sql.lib.php b/libraries/sql.lib.php index 6b08cb6d4a..6b42a737ca 100644 --- a/libraries/sql.lib.php +++ b/libraries/sql.lib.php @@ -1298,6 +1298,9 @@ function PMA_executeTheQuery($analyzed_sql_results, $full_sql_query, $is_gotofil function PMA_deleteTransformationInfo($db, $table, $analyzed_sql_results) { include_once 'libraries/transformations.lib.php'; + if (! isset($analyzed_sql_results['statement'])) { + return; + } $statement = $analyzed_sql_results['statement']; if ($statement instanceof PhpMyAdmin\SqlParser\Statements\AlterStatement) { if (!empty($statement->altered[0]) From 2b87c7d643516615474edd2d8fbf5659d34029d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Mon, 4 Sep 2017 14:59:57 +0200 Subject: [PATCH 8/8] Fix condition checking for result MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fixes #13637 Signed-off-by: Michal Čihař --- libraries/sql.lib.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/sql.lib.php b/libraries/sql.lib.php index 6b42a737ca..cb1682eef0 100644 --- a/libraries/sql.lib.php +++ b/libraries/sql.lib.php @@ -1660,7 +1660,7 @@ function PMA_getHtmlForSqlQueryResultsTable($displayResultsObject, } while ($GLOBALS['dbi']->moreResults() && $GLOBALS['dbi']->nextResult()); } else { - if (isset($result) && $result) { + if (isset($result) && $result !== false) { $fields_meta = $GLOBALS['dbi']->getFieldsMeta($result); $fields_cnt = count($fields_meta); }