method
form
form(method = "post", action = script_name, enctype = "application/x-www-form-urlencoded")
public
Generate a Form element as a string.
method should be either "get" or "post", and defaults to the latter. action defaults to the current CGI script name. enctype defaults to "application/x-www-form-urlencoded".
Alternatively, the attributes can be specified as a hash.
See also #multipart_form() for forms that include file uploads.
form{ "string" } # <FORM METHOD="post" ENCTYPE="application/x-www-form-urlencoded">string</FORM> form("get") { "string" } # <FORM METHOD="get" ENCTYPE="application/x-www-form-urlencoded">string</FORM> form("get", "url") { "string" } # <FORM METHOD="get" ACTION="url" ENCTYPE="application/x-www-form-urlencoded">string</FORM> form("METHOD" => "post", "ENCTYPE" => "enctype") { "string" } # <FORM METHOD="post" ENCTYPE="enctype">string</FORM>