forums::form::post_message (public)
forums::form::post_message [ -optional ] \ [ -show_anonymous_p show_anonymous_p ] \ [ -show_attachments_p show_attachments_p ] [ -prefix prefix ] \ form_name
Defined in packages/forums/tcl/form-procs.tcl
adds form elements to a form for the default post message form
- Switches:
- -optional (optional, boolean)
- -show_anonymous_p (optional, defaults to
"1"
)- -show_attachments_p (optional, defaults to
"1"
)- -prefix (optional)
- Parameters:
- form_name (required)
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.
Source code: template::element create $form_name ${prefix}forum_id -label [_ forums.forum_ID] -datatype integer -widget hidden template::element create $form_name ${prefix}parent_id -label [_ forums.parent_ID] -datatype integer -widget hidden -optional template::element create $form_name ${prefix}subscribe_p -label [_ forums.Subscribe] -datatype text -widget hidden -optional set options [list [list [_ forums.post_anonymously] 1 ] ] template::element create $form_name ${prefix}anonymous_p -label [_ forums.Anonymous] -datatype integer -widget [expr {$show_anonymous_p ? "checkbox" : "hidden"}] -options $options -optional set options [list [list [_ forums.No] 0] [list [_ forums.Yes] 1]] template::element create $form_name ${prefix}attach_p -label [_ forums.Attach] -datatype text -widget [expr {$show_attachments_p ? "radio" : "hidden"}] -options $options if {$optional_p} { template::element set_properties $form_name ${prefix}forum_id -optional template::element set_properties $form_name ${prefix}attach_p -optional }XQL Not present: Generic, PostgreSQL, Oracle