Index: openacs-4/packages/chat/www/ajax/chat.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/chat/www/ajax/Attic/chat.tcl,v diff -u -N -r1.1.2.3 -r1.1.2.4 --- openacs-4/packages/chat/www/ajax/chat.tcl 31 Mar 2006 16:09:56 -0000 1.1.2.3 +++ openacs-4/packages/chat/www/ajax/chat.tcl 7 Apr 2006 16:59:52 -0000 1.1.2.4 @@ -8,7 +8,7 @@ m id s - {msg ""} + {msg:optional,allhtml ""} } set message_output "" @@ -24,14 +24,15 @@ } # do not insert empty messages, if they managed to get here if { $msg ne "" } { - set message_output [c1 $m $msg] - set user_id [ad_conn user_id] - chat_message_post $id $user_id $msg f + set message_output [c1 add_msg $msg] + if { [c1 current_message_valid] } { + chat_message_post $id [c1 euid] [c1 emsg] f + } } } login - get_new - get_all { set message_output [c1 $m] - } + } get_updates { set message_output [c1 get_new] set user_output [c1 get_users] @@ -69,4 +70,4 @@ " -ns_return 200 text/html $output \ No newline at end of file +ns_return 200 text/html $output