template::widget::tab (public)

 template::widget::tab element_reference tag_attributes

Defined in packages/acs-templating/tcl/tab-procs.tcl

Widget to create one tab in a set of tabs ("tabstrip") in the tabbed UI.

Parameters:
element_reference - Reference variable to the form element
tag_attributes - HTML attributes to add to the tag
Returns:
Form HTML for the widget

Partial Call Graph (max 5 caller/called nodes):
%3

Testcases:
No testcase defined.
Source code:

  upvar $element_reference element

  if { [info exists element(html)] } {
    array set attributes $element(html)
  }

  array set attributes $tag_attributes

  if { !$element(current) } {

    set url $element(base_url)
    if { [string first "?" $url] >= 0 } {
      set joiner "&"
    } else {
      set joiner "?"
    }

    set id $element(form_id)
    set output "<a href=\"[ns_quotehtml ${url}${joiner}${id}_tab=$element(name)]\">"
    append output "$element(label)</a>"
  } else {  
    append output "<b>$element(label)</b>"
  }

  return $output
XQL Not present:
Generic, PostgreSQL, Oracle
[ hide source ] | [ make this the default ]
Show another procedure: