diff options
author | Marc Delisle <marc@infomarc.info> | 2011-02-09 01:36:05 +0300 |
---|---|---|
committer | Marc Delisle <marc@infomarc.info> | 2011-02-09 01:36:05 +0300 |
commit | 589d918ee7e4e747ce55f2f0c0905bc8d6fe1dc9 (patch) | |
tree | d98900836847745c1807b1254185e76ecd244588 /tbl_create.php | |
parent | 677e5a5da74080c0b08d8ca3e159aedc82670e76 (diff) |
Errors from the Ajax create table dialog where not displayed
Diffstat (limited to 'tbl_create.php')
-rw-r--r-- | tbl_create.php | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/tbl_create.php b/tbl_create.php index 6d569b50d7..4d3171ad99 100644 --- a/tbl_create.php +++ b/tbl_create.php @@ -350,12 +350,16 @@ if (isset($_REQUEST['do_save_data'])) { } exit; } else { - PMA_mysqlDie('', '', '', $err_url, false); - // An error happened while inserting/updating a table definition. - // to prevent total loss of that data, we embed the form once again. - // The variable $regenerate will be used to restore data in libraries/tbl_properties.inc.php - $num_fields = $_REQUEST['orig_num_fields']; - $regenerate = true; + if ($GLOBALS['is_ajax_request'] == true) { + PMA_ajaxResponse(PMA_DBI_getError(), false); + } else { + PMA_mysqlDie('', '', '', $err_url, false); + // An error happened while inserting/updating a table definition. + // to prevent total loss of that data, we embed the form once again. + // The variable $regenerate will be used to restore data in libraries/tbl_properties.inc.php + $num_fields = $_REQUEST['orig_num_fields']; + $regenerate = true; + } } } // end do create table |