251 |
$suffix = ' checked=1' if $value; |
$suffix = ' checked=1' if $value; |
252 |
$value_html = qq|<input type="checkbox" name="$name" title="$attr_type" value=1$suffix>|; |
$value_html = qq|<input type="checkbox" name="$name" title="$attr_type" value=1$suffix>|; |
253 |
push @checkboxes, $name; |
push @checkboxes, $name; |
254 |
} elsif ( ! defined $value ) { |
} elsif ( ! defined $value && ! $required->{$name} ) { |
255 |
$value_html = qq|<tt id="$name">undef</tt><!-- $name = undef -->|; # FIXME if $self->debug |
$value_html = qq|<tt id="$name">undef</tt><!-- $name = undef -->|; # FIXME if $self->debug |
256 |
} elsif ( $attr_type !~ m{^(Str|Int)$} || $value =~ $Frey::Web::re_html || $name =~ m{text} ) { |
} elsif ( $attr_type !~ m{^(Str|Int)$} || $value =~ $Frey::Web::re_html || $name =~ m{text} ) { |
257 |
$value_html = qq|<textarea name="$name" title="$attr_type">$value</textarea>|; |
$value_html = qq|<textarea name="$name" title="$attr_type">$value</textarea>|; |