[l2h] -local_icons bug

Erling D. Andersen Erling D. Andersen" <e.d.andersen@twi.tudelft.nl
Sun, 21 Mar 1999 16:49:25 +0100


I have installed the DOS version of latex2html. Unfortunately -local_icons does
work. At  least in my installation the icons are not copied to the destination

I am have never worked with PERL before but this new copy_icons
procedure seem to fix the problem (lines with # are the old lines):

sub copy_icons {
    print "\nCopying navigation icons ... ";
    foreach (keys %used_icons) {
        # each entry ends in gif or png
        if ($ALTERNATIVE_ICONS) {
#           &cp("$ALTERNATIVE_ICONS/$_", ".")
                if (-e "$ALTERNATIVE_ICONS/$_") && !(-e "$_");
        } elsif (/(gif|png)$/) {
#           &cp("$LATEX2HTMLDIR/icons.$1/$_",".")
                if (-e "$LATEX2HTMLDIR/icons.$1/$_") && !(-e "$_");

It seems that replacing "." by "$_" makes it works.

Regards, Erling