![]() |
| > Home > Documentation > Latest documentation > Interchange tags > button |
|
buttonCreates a HTML form submit button. Summary
ExamplesTag expansion example
Perl example
or similarly with positional parameters:
DescriptionThis tag can be used to render a standard HTML submit button, or a graphical button, to the page. Standard text-only submit buttons are created using the <input> HTML tag. Graphical buttons are created using the <a> and <img> HTML tags, along with a block of JavaScript to handle the submission. This tag has parameters that can be used to create button enhancements, such as a confirmation dialog. ParametersnameThe name given to the HTML <input> field. The default is "mv_click". srcIf set to an image file that exists then this tag will generate JavaScript and HTML to allow the image to be used as a submit button. If the named image file does not exist, or is not readable, then the text parameter will be used to build a standard HTML submit button. If the value starts with "http://" or "https://" then it will be used as-is and no existence checks will be performed.
textThe label for the standard HTML <input> button, if a graphic filename or URI is not provided. See the src parameter. This text will be used as the name of the scratchpad variable that will hold the callback code associated with the button. Also see the wait_text parameter. altAlternate text for the browser to show if the image can't be displayed, for whatever reason. This is also shown on the status bar and in tooltips, when the image is in focus. anchorHTML anchor name, if using an image as the submit button. confirmIf defined then the tag will produce a JavaScript confirmation dialog when the button is clicked. This parameter's value will be shown in the confirmation dialog. The form will only be submitted if the user confirms the click. extraAnything included in this parameter will be used verbatim as extra parameters to the generated HTML <img> tag (for image buttons) or <input> tag (for standard buttons). formThe name of the form that this button will submit. Defaults to the first form on the page. Naming forms is recommended to avoid unpredictable results. getsizeIf this parameter is set true, and the
Image::Size This parameter will override the values specified using the height and width parameters.
This parameter will be ignored if the src parameter refers to an external URI. hidetextSet true to suppress the text output. wait_textText to show while the next page is being loaded, to help prevent undesired multiple clicks on the button. If defined then this will be used, instead of the text parameter's value, to name the scratchpad variable that will hold the callback code associated with the button. borderOrdinary HTML attribute for the resulting HTML tag. heightOrdinary HTML attribute for the resulting HTML tag.
widthOrdinary HTML attribute for the resulting HTML tag.
hspaceOrdinary HTML attribute for the resulting HTML tag. vspaceOrdinary HTML attribute for the resulting HTML tag. alignOrdinary HTML attribute for the resulting HTML tag. idOrdinary CSS attribute for the resulting HTML tag. classOrdinary CSS attribute for the resulting HTML tag. styleOrdinary CSS attribute for the resulting HTML tag.
|
| Home | Legal nonsense | Privacy policy | Contact us |