chickadee » html-utils » hidden-input

hidden-input name/list #!optional value idprocedure

Generates an HTML hidden input field. name/list can be either a string representing the name attribute of the HTML input tag or an alist mapping names to values to be used by the corresponding input tags. When name/list is a string, so representing the name of the input tag, the optional values VALUE and ID can be used to be represent the values of their corresponding HTML attributes.

Examples:

(hidden-input 'secret-var "secret-val")

Produces:

 "<input type='hidden' name='secret-var' id='secret-var' value='secret-val'>"
(hidden-input '((secret-var1 . "secret-val1") (secret-var2 . "secret-val2")))

Produces:

 "<input type='hidden' id='secret-var1' name='secret-var1' value='secret-val1'><input type='hidden' id='secret-var2' name='secret-var2' value='secret-val2'>"