Merge branch 'QA_3_5'
Conflicts: js/tbl_select.js po/da.po tbl_select.php
This commit is contained in:
commit
c4a5af9182
@ -56,7 +56,9 @@ VerboseMultiSubmit, ReplaceHelpImg
|
||||
- bug #3547825 [edit] BLOB download no longer works
|
||||
- bug #3541966 [config] Error in generated configuration arrray
|
||||
- bug #3553551 [GUI] Invalid HTML code in multi submits confirmation form
|
||||
[interface] Designer sometimes places tables on the top menu
|
||||
- [interface] Designer sometimes places tables on the top menu
|
||||
- bug #3546277 [core] Call to undefined function __() when config file has wrong permissions
|
||||
- bug #3540922 [edit] Error searching table with many fields
|
||||
|
||||
3.5.2.1 (2012-08-03)
|
||||
- [security] Fixed local path disclosure vulnerability, see PMASA-2012-3
|
||||
|
||||
@ -52,7 +52,39 @@ $(function() {
|
||||
|
||||
PMA_prepareForAjaxRequest($search_form);
|
||||
|
||||
$.post($search_form.attr('action'), $search_form.serialize(), function(data) {
|
||||
var values = {};
|
||||
$search_form.find(':input').each(function() {
|
||||
var $input = $(this);
|
||||
if ($input.attr('type') == 'checkbox' || $input.attr('type') == 'radio') {
|
||||
if ($input.is(':checked')) {
|
||||
values[this.name] = $input.val();
|
||||
}
|
||||
} else {
|
||||
values[this.name] = $input.val();
|
||||
}
|
||||
});
|
||||
var columnCount = $('select[name="columnsToDisplay[]"] option').length;
|
||||
// Submit values only for the columns that have a search criteria
|
||||
for (var a = 0; a < columnCount; a++) {
|
||||
if (values['criteriaValues[' + a + ']'] == '') {
|
||||
delete values['criteriaValues[' + a + ']'];
|
||||
delete values['criteriaColumnOperators[' + a + ']'];
|
||||
delete values['criteriaColumnNames[' + a + ']'];
|
||||
delete values['criteriaColumnTypes[' + a + ']'];
|
||||
delete values['criteriaColumnCollations[' + a + ']'];
|
||||
}
|
||||
}
|
||||
// If all columns are selected, use a single parameter to indicate that
|
||||
if (values['columnsToDisplay[]'] != null) {
|
||||
if (values['columnsToDisplay[]'].length == columnCount) {
|
||||
delete values['columnsToDisplay[]'];
|
||||
values['displayAllColumns'] = true;
|
||||
}
|
||||
} else {
|
||||
values['displayAllColumns'] = true;
|
||||
}
|
||||
|
||||
$.post($search_form.attr('action'), values, function(data) {
|
||||
PMA_ajaxRemoveMessage($msgbox);
|
||||
if (data.success == true) {
|
||||
// found results
|
||||
|
||||
@ -634,8 +634,6 @@ class PMA_Config
|
||||
$this->checkPmaAbsoluteUri();
|
||||
$this->checkFontsize();
|
||||
|
||||
$this->checkPermissions();
|
||||
|
||||
// Handling of the collation must be done after merging of $cfg
|
||||
// (from config.inc.php) so that $cfg['DefaultConnectionCollation']
|
||||
// can have an effect. Note that the presence of collation
|
||||
|
||||
@ -639,10 +639,9 @@ EOT;
|
||||
if (isset($_POST['zoom_submit'])) {
|
||||
$sql_query .= '* ';
|
||||
} else {
|
||||
$sql_query .= (count($_POST['columnsToDisplay'])
|
||||
== count($_POST['criteriaColumnNames'])
|
||||
$sql_query .= ! empty($_POST['displayAllColumns'])
|
||||
? '* '
|
||||
: implode(', ', $this->getCommonFunctions()->backquote($_POST['columnsToDisplay'])));
|
||||
: implode(', ', $this->getCommonFunctions()->backquote($_POST['columnsToDisplay']));
|
||||
} // end if
|
||||
|
||||
$sql_query .= ' FROM ' . $this->getCommonFunctions()->backquote($_POST['table']);
|
||||
|
||||
@ -568,6 +568,8 @@ if ($GLOBALS['text_dir'] == 'ltr') {
|
||||
* check for errors occurred while loading configuration
|
||||
* this check is done here after loading language files to present errors in locale
|
||||
*/
|
||||
$GLOBALS['PMA_Config']->checkPermissions();
|
||||
|
||||
if ($GLOBALS['PMA_Config']->error_config_file) {
|
||||
$error = '[strong]' . __('Failed to read configuration file') . '[/strong]'
|
||||
. '[br][br]'
|
||||
|
||||
@ -41,7 +41,7 @@ $table_search = new PMA_TableSearch($db, $table, "normal");
|
||||
/**
|
||||
* Not selection yet required -> displays the selection form
|
||||
*/
|
||||
if (! isset($_POST['columnsToDisplay']) || $_POST['columnsToDisplay'][0] == '') {
|
||||
if (! isset($_POST['columnsToDisplay']) && ! isset($_POST['displayAllColumns'])) {
|
||||
// Gets some core libraries
|
||||
include_once 'libraries/tbl_common.inc.php';
|
||||
//$err_url = 'tbl_select.php' . $err_url;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user