From 477015901c379f8cd6ba46cfaa4a9ae284ae582d Mon Sep 17 00:00:00 2001 From: ivan Date: Tue, 15 Apr 2008 13:42:40 +0000 Subject: new package editor --- httemplate/elements/tr-input-text.html | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'httemplate/elements/tr-input-text.html') diff --git a/httemplate/elements/tr-input-text.html b/httemplate/elements/tr-input-text.html index 49ae166ee..f71f2f7fb 100644 --- a/httemplate/elements/tr-input-text.html +++ b/httemplate/elements/tr-input-text.html @@ -35,6 +35,11 @@ my $maxlength = $opt{'maxlength'} ? 'MAXLENGTH="'. $opt{'maxlength'}. '"' : ''; +$opt{'disabled'} = &{ $opt{'disabled'} }( \%opt ) + if ref($opt{'disabled'}) eq 'CODE'; +$opt{'disabled'} = 'DISABLED' + if $opt{'disabled'} && $opt{'disabled'} !~ /disabled/i; # uuh... yeah? + my @style = (); push @style, 'text-align: '. $opt{'text-align'} @@ -43,9 +48,6 @@ push @style, 'text-align: '. $opt{'text-align'} push @style, 'background-color: #dddddd' if $opt{'disabled'}; -$opt{'disabled'} = 'DISABLED' - if $opt{'disabled'} && $opt{'disabled'} !~ /disabled/i; # uuh... yeah? - my $style = scalar(@style) ? 'STYLE="'. join(';', @style). '"' : ''; my $cell_style = $opt{'cell_style'} ? 'STYLE="'. $opt{'cell_style'}. '"' : ''; -- cgit v1.2.1