Index: openacs-4/packages/acs-admin/www/apm/package-deinstall.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-admin/www/apm/package-deinstall.tcl,v diff -u -r1.1.1.1 -r1.1.1.1.10.1 --- openacs-4/packages/acs-admin/www/apm/package-deinstall.tcl 13 Mar 2001 22:59:26 -0000 1.1.1.1 +++ openacs-4/packages/acs-admin/www/apm/package-deinstall.tcl 30 Nov 2003 23:10:21 -0000 1.1.1.1.10.1 @@ -21,7 +21,7 @@ doc_body_append "" } on_error { if {![apm_version_installed_p $version_id] } { - ad_return_complaint "Database Error" "The database returned the following error + ad_return_complaint 1 "Database Error: The database returned the following error message
" } } Index: openacs-4/packages/acs-admin/www/apm/version-dependency-add-2.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-admin/www/apm/version-dependency-add-2.tcl,v diff -u -r1.4 -r1.4.2.1 --- openacs-4/packages/acs-admin/www/apm/version-dependency-add-2.tcl 17 May 2003 09:36:29 -0000 1.4 +++ openacs-4/packages/acs-admin/www/apm/version-dependency-add-2.tcl 30 Nov 2003 23:10:21 -0000 1.4.2.1 @@ -22,7 +22,7 @@ } default { - ad_return complaint "Dependency Entry Error" "Depenendencies are either provided or required." + ad_return_complaint 1 "Entry error: Depenendencies are either provided or required." } } apm_package_install_spec $version_id @@ -31,7 +31,7 @@ select count(*) from apm_package_dependencies where dependency_id = :dependency_id } -default 0] } { - ad_return_complaint "Database Error" "The database returned the following error: + ad_return_complaint 1 "The database returned the following error:[ad_quotehtml $errmsg]
" } } Index: openacs-4/packages/acs-admin/www/apm/version-dependency-remove.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-admin/www/apm/version-dependency-remove.tcl,v diff -u -r1.2 -r1.2.8.1 --- openacs-4/packages/acs-admin/www/apm/version-dependency-remove.tcl 10 Sep 2002 22:21:59 -0000 1.2 +++ openacs-4/packages/acs-admin/www/apm/version-dependency-remove.tcl 30 Nov 2003 23:10:21 -0000 1.2.8.1 @@ -20,12 +20,12 @@ } default { - ad_return complaint "Dependency Entry Error" "Depenendencies are either interfaces or requirements." + ad_return complaint 1 "Dependency Entry Error: Depenendencies are either interfaces or requirements." } } apm_package_install_spec $version_id } on_error { - ad_return_complaint "Database Error" "The database returned the following error: + ad_return_complaint 1 "Database Error: The database returned the following error:[ad_quotehtml $errmsg]
" } Index: openacs-4/packages/acs-admin/www/apm/version-generate-tarball.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-admin/www/apm/version-generate-tarball.tcl,v diff -u -r1.3 -r1.3.4.1 --- openacs-4/packages/acs-admin/www/apm/version-generate-tarball.tcl 10 Mar 2003 19:59:31 -0000 1.3 +++ openacs-4/packages/acs-admin/www/apm/version-generate-tarball.tcl 30 Nov 2003 23:10:21 -0000 1.3.4.1 @@ -11,7 +11,7 @@ db_transaction { apm_generate_tarball $version_id } on_error { - ad_return_complaint "APM Generation Error" "The database returned the following error message: + ad_return_complaint 1 "APM Generation Error: The database returned the following error message:[ad_quotehtml $errmsg]
[ad_quotehtml $errmsg] Index: openacs-4/packages/acs-admin/www/apm/version-i18n-process-2.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-admin/www/apm/version-i18n-process-2.tcl,v diff -u -r1.13 -r1.13.2.1 --- openacs-4/packages/acs-admin/www/apm/version-i18n-process-2.tcl 13 Oct 2003 16:37:48 -0000 1.13 +++ openacs-4/packages/acs-admin/www/apm/version-i18n-process-2.tcl 30 Nov 2003 23:10:21 -0000 1.13.2.1 @@ -55,7 +55,7 @@ # We need either or both of the actions to be selected if { (! $replace_text_p) && (! $replace_tags_p) } { - ad_return_complaint "Invalid HTML Parameters" "You must choose an action to take on selected adp files, either replace_text or replace_tags or both." + ad_return_complaint 1 "Invalid HTML Parameters: you must choose an action to take on selected adp files, either replace_text or replace_tags or both." ad_script_abort } Index: openacs-4/packages/acs-admin/www/users/member-state-change.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-admin/www/users/member-state-change.tcl,v diff -u -r1.9 -r1.9.8.1 --- openacs-4/packages/acs-admin/www/users/member-state-change.tcl 18 Sep 2002 14:54:47 -0000 1.9 +++ openacs-4/packages/acs-admin/www/users/member-state-change.tcl 30 Nov 2003 23:10:21 -0000 1.9.8.1 @@ -29,7 +29,7 @@ where user_id = :user_id }]} { # The user is not in there - ad_return_complaint "Invalid User" "The user is not in the system" + ad_return_complaint 1 "Invalid User: the user is not in the system" return } @@ -70,7 +70,7 @@ } if [empty_string_p $action] { - ad_return_complaint "Not valid action" "You have not changed the user in any way" + ad_return_complaint 1 "Not valid action: You have not changed the user in any way" return } Index: openacs-4/packages/acs-subsite/www/admin/site-map/package-new.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-subsite/www/admin/site-map/package-new.tcl,v diff -u -r1.9.2.1 -r1.9.2.2 --- openacs-4/packages/acs-subsite/www/admin/site-map/package-new.tcl 26 Nov 2003 16:07:19 -0000 1.9.2.1 +++ openacs-4/packages/acs-subsite/www/admin/site-map/package-new.tcl 30 Nov 2003 23:10:21 -0000 1.9.2.2 @@ -62,7 +62,7 @@ } on_error { if {![db_string package_new_doubleclick_ck {} -default 0]} { - ad_return_complaint "Error Creating Package" "The following error was generated + ad_return_complaint 1 "Error Creating Package: The following error was generated when attempting to create the package[ad_quotehtml $errmsg] Index: openacs-4/packages/categories/www/cadmin/category-delete-2.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/categories/www/cadmin/category-delete-2.tcl,v diff -u -r1.1.1.1 -r1.1.1.1.2.1 --- openacs-4/packages/categories/www/cadmin/category-delete-2.tcl 23 Apr 2003 12:29:27 -0000 1.1.1.1 +++ openacs-4/packages/categories/www/cadmin/category-delete-2.tcl 30 Nov 2003 23:10:21 -0000 1.1.1.1.2.1 @@ -17,7 +17,7 @@ category::delete $category_id category_tree::flush_cache $tree_id } on_error { - ad_return_complaint "Error Deleting Node" "This node contains leaf (child) nodes. If you really want to delete those leaf nodes, plesae delete them first. Thank you." + ad_return_complaint 1 "Error Deleting Node
This node contains leaf (child) nodes. If you really want to delete those leaf nodes, plesae delete them first. Thank you." return } Index: openacs-4/packages/categories/www/cadmin/tree-update-2.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/categories/www/cadmin/Attic/tree-update-2.tcl,v diff -u -r1.3 -r1.3.2.1 --- openacs-4/packages/categories/www/cadmin/tree-update-2.tcl 19 May 2003 13:10:51 -0000 1.3 +++ openacs-4/packages/categories/www/cadmin/tree-update-2.tcl 30 Nov 2003 23:10:21 -0000 1.3.2.1 @@ -33,8 +33,8 @@ } db_dml delete_tmp_category_trees "" -if { [llength $list_of_errors] >0 } { - ad_return_complaint "Error Deleting Nodes" $list_of_errors +if { [llength $list_of_errors] > 0 } { + ad_return_complaint [llength $list_of_errors] "Error Deleting Nodes: $list_of_errors" return } Index: openacs-4/packages/chat/tcl/chat-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/chat/tcl/chat-procs.tcl,v diff -u -r1.3 -r1.3.2.1 --- openacs-4/packages/chat/tcl/chat-procs.tcl 1 Nov 2003 08:45:37 -0000 1.3 +++ openacs-4/packages/chat/tcl/chat-procs.tcl 30 Nov 2003 23:10:21 -0000 1.3.2.1 @@ -506,7 +506,7 @@ returning contents into :1 } -clobs [list $contents] } on_error { - ad_return_complaint "Insert fail" $errmsg + ad_return_complaint 1 "Insert fail: $errmsg" } return $transcript_id Index: openacs-4/packages/chat/www/chat.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/chat/www/chat.tcl,v diff -u -r1.3 -r1.3.6.1 --- openacs-4/packages/chat/www/chat.tcl 18 Sep 2002 13:03:47 -0000 1.3 +++ openacs-4/packages/chat/www/chat.tcl 30 Nov 2003 23:10:22 -0000 1.3.6.1 @@ -26,7 +26,7 @@ } if { [catch {set room_name [chat_room_name $room_id]} errmsg] } { - ad_return_complaint "Room not found" "Invalid room id" + ad_return_complaint 1 "Room not found, Invalid room id" } set context_bar [list $room_name] Index: openacs-4/packages/chat/www/message-delete-2.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/chat/www/message-delete-2.tcl,v diff -u -r1.1.1.1 -r1.1.1.1.8.1 --- openacs-4/packages/chat/www/message-delete-2.tcl 20 Apr 2001 20:51:08 -0000 1.1.1.1 +++ openacs-4/packages/chat/www/message-delete-2.tcl 30 Nov 2003 23:10:22 -0000 1.1.1.1.8.1 @@ -12,7 +12,7 @@ ad_require_permission $room_id chat_room_delete if { [catch {chat_room_message_delete $room_id} errmsg] } { - ad_return_complaint "Delete messages failed." $errmsg + ad_return_complaint 1 "Delete messages failed: $errmsg" } ad_returnredirect . \ No newline at end of file Index: openacs-4/packages/chat/www/room-delete-2.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/chat/www/room-delete-2.tcl,v diff -u -r1.1.1.1 -r1.1.1.1.8.1 --- openacs-4/packages/chat/www/room-delete-2.tcl 20 Apr 2001 20:51:08 -0000 1.1.1.1 +++ openacs-4/packages/chat/www/room-delete-2.tcl 30 Nov 2003 23:10:22 -0000 1.1.1.1.8.1 @@ -12,7 +12,7 @@ ad_require_permission $room_id chat_room_delete if { [catch {chat_room_delete $room_id} errmsg] } { - ad_return_complaint "Delete room failed." $errmsg + ad_return_complaint 1 "Delete room failed: $errmsg" } ad_returnredirect . Index: openacs-4/packages/chat/www/room-edit-2.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/chat/www/Attic/room-edit-2.tcl,v diff -u -r1.2 -r1.2.6.1 --- openacs-4/packages/chat/www/room-edit-2.tcl 10 Sep 2002 22:22:32 -0000 1.2 +++ openacs-4/packages/chat/www/room-edit-2.tcl 30 Nov 2003 23:10:22 -0000 1.2.6.1 @@ -18,7 +18,7 @@ if {[catch {chat_room_edit $room_id $pretty_name $description $moderated_p $active_p $archive_p} errmsg]} { - ad_return_complaint "Could not update room" $errmsg + ad_return_complaint 1 "Could not update room: $errmsg" } Index: openacs-4/packages/chat/www/room-edit.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/chat/www/room-edit.tcl,v diff -u -r1.2 -r1.2.6.1 --- openacs-4/packages/chat/www/room-edit.tcl 4 Sep 2002 08:12:51 -0000 1.2 +++ openacs-4/packages/chat/www/room-edit.tcl 30 Nov 2003 23:10:22 -0000 1.2.6.1 @@ -27,7 +27,7 @@ from chat_rooms where room_id = :room_id}} errmsg]} { - ad_return_complaint "Room not found" "Room not found." + ad_return_complaint 1 "Room not found." } set context_bar [list "Edit room '$pretty_name'"] Index: openacs-4/packages/chat/www/room-new-2.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/chat/www/Attic/room-new-2.tcl,v diff -u -r1.1.1.1 -r1.1.1.1.8.1 --- openacs-4/packages/chat/www/room-new-2.tcl 20 Apr 2001 20:51:08 -0000 1.1.1.1 +++ openacs-4/packages/chat/www/room-new-2.tcl 30 Nov 2003 23:10:22 -0000 1.1.1.1.8.1 @@ -26,7 +26,7 @@ -context_id $package_id \ -creation_user $user_id \ -creation_ip $creation_ip $pretty_name]} errmsg]} { - ad_return_complaint "Create new room failed." $errmsg + ad_return_complaint 1 "Create new room failed: $errmsg" } ad_returnredirect "room?room_id=$room_id" Index: openacs-4/packages/chat/www/transcript-delete-2.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/chat/www/transcript-delete-2.tcl,v diff -u -r1.1.1.1 -r1.1.1.1.8.1 --- openacs-4/packages/chat/www/transcript-delete-2.tcl 20 Apr 2001 20:51:08 -0000 1.1.1.1 +++ openacs-4/packages/chat/www/transcript-delete-2.tcl 30 Nov 2003 23:10:22 -0000 1.1.1.1.8.1 @@ -10,7 +10,7 @@ ad_require_permission $transcript_id chat_transcript_delete if { [catch {chat_transcript_delete $transcript_id} errmsg] } { - ad_return_complaint "Delete transcript failed." $errmsg + ad_return_complaint 1 "Delete transcript failed: $errmsg" } ad_returnredirect "room?room_id=$room_id" Index: openacs-4/packages/chat/www/transcript-edit-2.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/chat/www/Attic/transcript-edit-2.tcl,v diff -u -r1.1.1.1 -r1.1.1.1.8.1 --- openacs-4/packages/chat/www/transcript-edit-2.tcl 20 Apr 2001 20:51:08 -0000 1.1.1.1 +++ openacs-4/packages/chat/www/transcript-edit-2.tcl 30 Nov 2003 23:10:22 -0000 1.1.1.1.8.1 @@ -16,7 +16,7 @@ ad_require_permission $transcript_id chat_transcript_edit if { [catch {chat_transcript_edit $transcript_id $transcript_name $description $contents} errmsg] } { - ad_return_complaint "Could not update transcript" $errmsg + ad_return_complaint 1 "Could not update transcript: $errmsg" } ad_returnredirect "transcript-view?transcript_id=$transcript_id&room_id=$room_id" \ No newline at end of file Index: openacs-4/packages/download/www/all-metadata.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/download/www/all-metadata.tcl,v diff -u -r1.2 -r1.2.6.1 --- openacs-4/packages/download/www/all-metadata.tcl 10 Sep 2002 22:22:34 -0000 1.2 +++ openacs-4/packages/download/www/all-metadata.tcl 30 Nov 2003 23:10:22 -0000 1.2.6.1 @@ -16,7 +16,7 @@ where dam.linked_p = 't' and dam.metadata_id = :metadata_id }] } { - ad_return_complaint "Not found" "Metadata id not found" + ad_return_complaint 1 "Metadata id not found" } set answer_column [download_metadata_column $data_type] set metadata_select "metadata$metadata_id" Index: openacs-4/packages/download/www/one-metadata.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/download/www/one-metadata.tcl,v diff -u -r1.3 -r1.3.6.1 --- openacs-4/packages/download/www/one-metadata.tcl 10 Sep 2002 22:22:34 -0000 1.3 +++ openacs-4/packages/download/www/one-metadata.tcl 30 Nov 2003 23:10:22 -0000 1.3.6.1 @@ -16,7 +16,7 @@ where dam.linked_p = 't' and dam.metadata_id = :metadata_id }] } { - ad_return_complaint "Not found" "Metadata id not found" + ad_return_complaint 1 "Metadata id not found" } set answer_column [download_metadata_column $data_type] Index: openacs-4/packages/ecommerce/tcl/ecommerce-widgets-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/ecommerce/tcl/ecommerce-widgets-procs.tcl,v diff -u -r1.14 -r1.14.6.1 --- openacs-4/packages/ecommerce/tcl/ecommerce-widgets-procs.tcl 10 Sep 2002 22:22:36 -0000 1.14 +++ openacs-4/packages/ecommerce/tcl/ecommerce-widgets-procs.tcl 30 Nov 2003 23:10:22 -0000 1.14.6.1 @@ -1014,7 +1014,7 @@ } { if { ![regexp -nocase {([0-9]+):([0-9]+):([0-9]+)} $timestamp match hours mins secs]} { - ad_return_complaint "1" "
The time part of the timestamp is not in the correct format. It must be HH12:MI:SS" + ad_return_complaint 1 " The time part of the timestamp is not in the correct format. It must be HH12:MI:SS" return -code return } else { Index: openacs-4/packages/file-manager/www/file-upload-2.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/file-manager/www/file-upload-2.tcl,v diff -u -r1.7.2.1 -r1.7.2.2 --- openacs-4/packages/file-manager/www/file-upload-2.tcl 26 Nov 2003 14:34:42 -0000 1.7.2.1 +++ openacs-4/packages/file-manager/www/file-upload-2.tcl 30 Nov 2003 23:10:22 -0000 1.7.2.2 @@ -20,12 +20,12 @@ # Make sure the incoming filename is valid if ![fm_valid_filename_p $title] { - ad_return_complaint "Error" " Invalid file name (no spaces, & or /'s)" + ad_return_complaint 1 " Invalid file name (no spaces, & or /'s)" ad_script_abort } if {![empty_string_p $title] && [empty_string_p [file ext $title]]} { - ad_return_complaint "Error" " + ad_return_complaint 1 " The title you supply must have one of the following extensions:
[ad_parameter Extensions file-manager]" ad_script_abort Index: openacs-4/packages/logger/www/admin/variable-delete.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/logger/www/admin/variable-delete.tcl,v diff -u -r1.3 -r1.3.6.1 --- openacs-4/packages/logger/www/admin/variable-delete.tcl 8 May 2003 13:56:04 -0000 1.3 +++ openacs-4/packages/logger/www/admin/variable-delete.tcl 30 Nov 2003 23:10:22 -0000 1.3.6.1 @@ -17,7 +17,7 @@ set n_log_entries [db_string n_log_entries {}] if { $n_log_entries > 0 } { - ad_return_complaint "Variable is in use" "You cannot delete this variable as it is being used by log entries" + ad_return_complaint 1 "Variable is in use: you cannot delete this variable as it is being used by log entries" ad_script_abort }