XLS engine now compatible med PEAR Excel Writer.
[fa-stable.git] / admin / change_current_user_password.php
index 0118d8cb80ac27fef8e9aa9103ee98e457b52ae0..d38f96cd2b3a679e2ca3ba0c61f1e5e562e70bb9 100644 (file)
@@ -55,8 +55,12 @@ if (isset($_POST['UPDATE_ITEM']))
 
        if (can_process())
        {
-               update_user_password($_POST['user_id'], md5($_POST['password']));
-           display_notification(_("Your password has been updated."));
+               if ($allow_demo_mode) {
+                   display_warning(_("Password cannot be changed in demo mode."));
+               } else {
+                       update_user_password($_POST['user_id'], md5($_POST['password']));
+                   display_notification(_("Your password has been updated."));
+               }
                $Ajax->activate('_page_body');
        }
 }