anchor_form (public)

 anchor_form [ -id id ] [ -vars vars ] [ -action action ] \
    [ -label label ]

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

return an inline form with the appearance of an anchor

Switches:
-id (optional)
-vars (optional)
-action (optional)
-label (optional, defaults to "link")

Partial Call Graph (max 5 caller/called nodes):
%3 packages/acs-admin/www/apm/package-delete-2.tcl packages/acs-admin/ www/apm/package-delete-2.tcl anchor_form anchor_form packages/acs-admin/www/apm/package-delete-2.tcl->anchor_form template::add_body_script template::add_body_script (public) anchor_form->template::add_body_script

Testcases:
No testcase defined.
Source code:
  set inputs ""
  foreach {name value} $vars {
    append inputs "<input type='hidden' name='$name' value='$value'>"
  }
  template::add_body_script -script [subst {
      document.getElementById('$id-control').addEventListener('click', function (event) {
        event.preventDefault();
        document.getElementById('$id').submit();
        return false;
      });
    }]
  return [subst {
    <form id="$id" action="$action" method="post" style='display:inline;'>$inputs<a id='$id-control' href="#" class='button'>[ns_quotehtml $label]</a></form>
  }]
XQL Not present:
Generic, PostgreSQL, Oracle
[ hide source ] | [ make this the default ]
Show another procedure: