X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Felements%2Fcity.html;h=29495df43f6382a990f5b6265b79acd79b77f3f3;hb=ea3ce8d7f076e7fecff4be7ae63bc413adb0adf5;hp=d774cce5942c76730826a0d8e49b0478ef6dc76d;hpb=22773e1b0288fc296c30ba99e2d37a8f4193a462;p=freeside.git diff --git a/httemplate/elements/city.html b/httemplate/elements/city.html index d774cce59..29495df43 100644 --- a/httemplate/elements/city.html +++ b/httemplate/elements/city.html @@ -65,9 +65,10 @@ Example: what.form.<% $pre %>city.style.display = 'none'; what.form.<% $pre %>city_select.style.display = ''; } else if ( what.form.<% $pre %>city.style.display == 'none' ) { + // turn on the text city, turn off the select + what.form.<%$ pre %>city.value = saved_<%$pre%>city; what.form.<% $pre %>city.style.display = ''; what.form.<% $pre %>city_select.style.display = 'none'; - what.form.<%$ pre %>city.value = saved_<%$pre%>city; } //run the callback @@ -122,6 +123,9 @@ my $pre = $opt{'prefix'}; my $text_style = $opt{'style'} ? [ @{ $opt{'style'} } ] : []; my $select_style = $opt{'style'} ? [ @{ $opt{'style'} } ] : []; +push @$text_style, @{ $opt{'text_style'} } if $opt{'text_style'}; +push @$select_style, @{ $opt{'select_style'} } if $opt{'select_style'}; + my @cities = cities( $opt{'county'}, $opt{'state'}, $opt{'country'} ); my $saved_city = ''; if ( scalar(@cities) > 1 || $cities[0] ) {