XHTML Bugfixes
This commit is contained in:
parent
3d65ae2158
commit
0a0195fd60
4 changed files with 17 additions and 7 deletions
|
|
@ -89,7 +89,11 @@ Renders a button.
|
|||
sub toHtml {
|
||||
my $self = shift;
|
||||
my $value = $self->fixQuotes($self->{value});
|
||||
return '<input type="button" name="'.$self->{name}.'" value="'.$value.'" id="'.$self->{id}.'" '.$self->{extras}.' />';
|
||||
my $html = '<input type="button" ';
|
||||
$html .= 'name="'.$self->{name}.'" ' if ($self->{name});
|
||||
$html .= 'id="'.$self->{id}.'" ' unless ($self->{id} eq "_formId");
|
||||
$html .= 'value="'.$value.'" '.$self->{extras}.' />';
|
||||
return $html;
|
||||
}
|
||||
|
||||
1;
|
||||
|
|
|
|||
|
|
@ -94,13 +94,13 @@ sub toHtmlAsHidden {
|
|||
|
||||
=head2 toHtmlWithWrapper ( )
|
||||
|
||||
A synonym for toHtmlAsHidden.
|
||||
Renders the form field to HTML as a table row. The row is not displayed because there is nothing to display, but it may not be left away because <input> may not be a child of <table> according to the XHTML standard.
|
||||
|
||||
=cut
|
||||
|
||||
sub toHtmlWithWrapper {
|
||||
my $self = shift;
|
||||
return $self->toHtmlAsHidden;
|
||||
return '<tr style="display: none"><td></td><td>'.$self->toHtmlAsHidden.'</td></tr>';
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -96,8 +96,10 @@ Renders an input tag of type password.
|
|||
|
||||
sub toHtml {
|
||||
my $self = shift;
|
||||
return '<input type="password" name="'.$self->{name}.'" value="'.$self->fixQuotes($self->{value}).'" size="'.
|
||||
$self->{size}.'" id="'.$self->{id}.'" maxlength="'.$self->{maxLength}.'" '.$self->{extras}.' />';
|
||||
my $html = '<input type="password" name="'.$self->{name}.'" value="'.$self->fixQuotes($self->{value}).'" size="'.$self->{size}.'" id="'.$self->{id}.'" ';
|
||||
$html .= 'maxlength="'.$self->{maxLength}.'" ' if ($self->{maxLength});
|
||||
$html .= $self->{extras}.' />';
|
||||
return $html;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -60,9 +60,13 @@ Renders a button.
|
|||
|
||||
sub toHtml {
|
||||
my $self = shift;
|
||||
my $value = $self->fixQuotes($self->{value});
|
||||
my $value = $self->fixQuotes($self->{value});
|
||||
$self->{extras} ||= 'onclick="this.value=\''.WebGUI::International::get(452).'\'"';
|
||||
return '<input id="'.$self->{id}.'" type="submit" name="'.$self->{name}.'" value="'.$value.'" '.$self->{extras}.' />';
|
||||
my $html = '<input type="submit" ';
|
||||
$html .= 'name="'.$self->{name}.'" ' if ($self->{name});
|
||||
$html .= 'id="'.$self->{id}.'" ' unless ($self->{id} eq "_formId");
|
||||
$html .= 'value="'.$value.'" '.$self->{extras}.' />';
|
||||
return $html;
|
||||
}
|
||||
|
||||
1;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue