| 1 | |||
| 2 | ################################################################################### | ||
| 3 | # | ||
| 4 | # Embperl - Copyright (c) 1997-2008 Gerald Richter / ecos gmbh www.ecos.de | ||
| 5 | # Embperl - Copyright (c) 2008-2015 Gerald Richter | ||
| 6 | # Embperl - Copyright (c) 2015-2023 actevy.io | ||
| 7 | # | ||
| 8 | # You may distribute under the terms of either the GNU General Public | ||
| 9 | # License or the Artistic License, as specified in the Perl README file. | ||
| 10 | # | ||
| 11 | # THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR | ||
| 12 | # IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED | ||
| 13 | # WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. | ||
| 14 | # | ||
| 15 | # $Id$ | ||
| 16 | # | ||
| 17 | ################################################################################### | ||
| 18 | |||
| 19 | package Embperl::Form::Control::submit ; | ||
| 20 | |||
| 21 | use strict ; | ||
| 22 | use base 'Embperl::Form::Control' ; | ||
| 23 | |||
| 24 | use Embperl::Inline ; | ||
| 25 | |||
| 26 | 1 ; | ||
| 27 | |||
| 28 | __EMBPERL__ | ||
| 29 | |||
| 30 | [# --------------------------------------------------------------------------- | ||
| 31 | # | ||
| 32 | # show - output the control | ||
| 33 | #] | ||
| 34 | |||
| 35 | [$ sub show ($self, $data) | ||
| 36 | |||
| 37 | my $span = ($self->{width_percent}) ; | ||
| 38 | $] | ||
| 39 | <td class="cBase cControlBox cControlButtonBox" colspan="[+ $span +]"> | ||
| 40 | <input class="cBase cControl cControlButton" name="[+ $self->{name} +]" | ||
| 41 | value="[+ $self->{value} || $self->{text} +]" | ||
| 42 | title="[+ $self->{text} +]" | ||
| 43 | [$if $self -> {novalidate} $] onClick="doValidate = 0;" [$endif$] | ||
| 44 | [$if $self -> {image} $] | ||
| 45 | type="image" src="[+ $self -> {image} +]" | ||
| 46 | [$else$] | ||
| 47 | type="submit" | ||
| 48 | [$endif$] | ||
| 49 | > | ||
| 50 | </td> | ||
| 51 | [$endsub$] | ||
| 52 | |||
| 53 | __END__ |