checkbox_group

checkbox_group(name = "", *values) Instance Public methods Generate a sequence of checkbox elements, as a String. The checkboxes will all have the same name attribute. Each checkbox is followed by a label. There will be one checkbox for each value. Each value can be specified as a String, which will be used both as the value of the VALUE attribute and as the label for that checkbox. A single-element array has the same effect. Each value can also be specified as a three-element arr

checkbox

checkbox(name = "", value = nil, checked = nil) Instance Public methods Generate a Checkbox Input element as a string. The attributes of the element can be specified as three arguments, name, value, and checked. checked is a boolean value; if true, the CHECKED attribute will be included in the element. Alternatively, the attributes can be specified as a hash. checkbox("name") # = checkbox("NAME" => "name") checkbox("name", "value") # = checkbox("NAME" => "name", "VALUE"

caption

caption(align = {}) Instance Public methods Generate a Table Caption element as a string. align can be a string, giving the alignment of the caption (one of top, bottom, left, or right). It can be a hash of all the attributes of the element. Or it can be omitted. The body of the element is provided by the passed-in no-argument block. caption("left") { "Capital Cities" } # => <CAPTION ALIGN=\"left\">Capital Cities</CAPTION>

blockquote

blockquote(cite = {}) Instance Public methods Generate a BlockQuote element as a string. cite can either be a string, give the URI for the source of the quoted text, or a hash, giving all attributes of the element, or it can be omitted, in which case the element has no attributes. The body is provided by the passed-in no-argument block blockquote("http://www.example.com/quotes/foo.html") { "Foo!" } #=> "<BLOCKQUOTE CITE=\"http://www.example.com/quotes/foo.html\">Foo!<

base

base(href = "") Instance Public methods Generate a Document Base URI element as a String. href can either by a string, giving the base URL for the HREF attribute, or it can be a has of the element's attributes. The passed-in no-argument block is ignored. base("http://www.example.com/cgi") # => "<BASE HREF=\"http://www.example.com/cgi\">"

a

a(href = "") Instance Public methods Generate an Anchor element as a string. href can either be a string, giving the URL for the HREF attribute, or it can be a hash of the element's attributes. The body of the element is the string returned by the no-argument block passed in. a("http://www.example.com") { "Example" } # => "<A HREF=\"http://www.example.com\">Example</A>" a("HREF" => "http://www.example.com", "TARGET" => "_top") { "Example" } # => "<A

value=

value=(val) Instance Public methods Replaces the value of this cookie with a new value or list of values.

value

value() Instance Public methods Returns the value or list of values for this cookie.

to_s

to_s() Instance Public methods Convert the Cookie to its string representation.

secure=

secure=(val) Instance Public methods Set whether the Cookie is a secure cookie or not. val must be a boolean.