Conditional Ajax for change password form
This commit is contained in:
@@ -2007,8 +2007,9 @@ $(document).ready(function() {
|
||||
* Attach Ajax event handler for Change Password form submission
|
||||
*
|
||||
* @uses PMA_ajaxShowMessage()
|
||||
* @see $cfg['AjaxEnable']
|
||||
*/
|
||||
$("#change_password_form").find('input[name=change_pw]').live('click', function(event) {
|
||||
$("#change_password_form.ajax").find('input[name=change_pw]').live('click', function(event) {
|
||||
event.preventDefault();
|
||||
|
||||
/**
|
||||
|
@@ -19,7 +19,7 @@ $chg_evt_handler = (PMA_USR_BROWSER_AGENT == 'IE' && PMA_USR_BROWSER_VER >= 5)
|
||||
|
||||
// Displays the form
|
||||
?>
|
||||
<form method="post" id="change_password_form" action="<?php echo $GLOBALS['PMA_PHP_SELF']; ?>" name="chgPassword" onsubmit="return checkPassword(this)">
|
||||
<form method="post" id="change_password_form" action="<?php echo $GLOBALS['PMA_PHP_SELF']; ?>" name="chgPassword" <?php echo ($GLOBALS['cfg']['AjaxEnable'] ? 'class="ajax" ' : ''); ?> onsubmit="return checkPassword(this)">
|
||||
<?php echo PMA_generate_common_hidden_inputs();
|
||||
if (strpos($GLOBALS['PMA_PHP_SELF'], 'server_privileges') !== false) {
|
||||
echo '<input type="hidden" name="username" value="' . htmlspecialchars($username) . '" />' . "\n"
|
||||
|
Reference in New Issue
Block a user