[ic] image tag suggestion

Steve Graham icdev at mrlock.com
Sun Jun 22 02:38:41 UTC 2008


Hello,

I was working with the system tag image and noticed there was not a way to 
enter a name to the img html rendition.
Any problems with adding name to the list of ordinary html attributes?

  my $opts = '';
        for (qw: width height alt title border hspace vspace align valign 
style class :) {
                if (defined $opt->{$_}) {
                        my $val = $opt->{$_};
                        $val = HTML::Entities::encode($val) if $val =~ /\W/;
                        $opts .= qq{ $_="$val"};
                }
        }


suggestion:

  my $opts = '';
+        for (qw: name width height alt title border hspace vspace align 
valign style class :) {
                if (defined $opt->{$_}) {
                        my $val = $opt->{$_};
                        $val = HTML::Entities::encode($val) if $val =~ /\W/;
                        $opts .= qq{ $_="$val"};
                }
        }


Steve 




More information about the interchange-users mailing list