display_message() function

Hegedüs Ervin airween at damson.hu
Mon Jan 9 23:26:48 CET 2006


hello,

i made a simple password changer site for our webmail.

i try to handle with user errors with display_message()
JS function, but something wrong...

code:

.
if ($_REQUEST['pass'] == "mismatch") {
  // passwords mismatch
?>

<script type="text/javascript">
<!--
var rcmail = new rcube_webmail();

rcmail.set_env('comm_path', 'pass.php?');

rcmail.display_message('ERROR: password mismatch!', 'warning');
rcmail.set_env('task', 'login');
rcmail.set_env('action', 'login');
rcmail.gui_object('message', 'message');
rcmail.gui_object('loginform', 'form');

-->
</script>;

<?
}
..

but nothing happened...

it looks like in display_message() function at this line
stops the code:

    if (!this.gui_objects.message)
      return false;


what may be the problem?


thank you:

a.






More information about the Dev mailing list