NAME

Apache::Wyrd::Input::Opt - Wyrd for passing options to Apache::Wyrd::Input::Set

SYNOPSIS

see SYNOPSIS for Apache::Wyrd::Input::Set

DESCRIPTION

Roughly equivalent to the <option> HTML tag, but for Apache::Wyrd::Input::Set objects, rather than for <select> tags. Opt provides an option to a Set Input. The label is given either as the value attribute or as the enclosed text. The name attribute is the value added to the list of values for the affected parameter.

HTML ATTRIBUTES

Opt accepts most attributes that can be handed to the appropriate HTML tag, i.e. <option>, <checkbox>, or <radio>. These are:

  • class

  • onchange

  • onselect

  • onblur

  • onfocus

  • disabled

disabled is set if the attribute disable is set to some value or if the disabled flag is set.

name

The value this option will represent

value

The label this option will have (Optional). If not set, the label will be the same as the name.

PERL METHODS

(format: (returns) name (arguments after self))

(scalar) name (void)

The option name.

(scalar) value (void)

The option label

(scalar) radiobutton (void)

Return the template for a radiobutton, based on the attributes given this Opt. Called by Apache::Wyrd::Input::Set when making a radiobuttons interface.

(scalar) checkbox (void)

Return the template for a checkbox, based on the attributes given this Opt. Called by Apache::Wyrd::Input::Set when making a radiobuttons interface.

(scalar) option (void)

Return the template for a option, based on the attributes given this Opt. Called by Apache::Wyrd::Input::Set when making a radiobuttons interface.

BUGS/CAVEATS

Reserves the _format_output, _generate_output, and final_output methods.

AUTHOR

Barry King <wyrd@nospam.wyrdwright.com>

SEE ALSO

Apache::Wyrd

General-purpose HTML-embeddable perl object

LICENSE

Copyright 2002-2004 Wyrdwright, Inc. and licensed under the GNU GPL.

See LICENSE under the documentation for Apache::Wyrd.