changeset 108:49db8f7d9833 misc

Fix handling of prefixes with directory paths.
author Matti Hamalainen <ccr@tnsp.org>
date Sun, 05 Dec 2010 23:48:46 +0000
parents d40580ef29d0
children 682b8c0d574a
files magestats.pl
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/magestats.pl	Mon Oct 04 13:12:29 2010 +0000
+++ b/magestats.pl	Sun Dec 05 23:48:46 2010 +0000
@@ -497,7 +497,8 @@
   $spells->{$type}{"essence"}{"increase"};
     
   if (exists($spells->{$type}{"essence"}{"blasts"})) {
-    print OUT "<img src=\"".$opt_prefix."_".$type.".".$opt_imgfmt."\" alt=\"?\" />";
+    my ($gfilename, $gpath, $gsuffix) = fileparse($opt_prefix);
+    print OUT "<img src=\"".$gfilename.$gsuffix."_".$type.".".$opt_imgfmt."\" alt=\"?\" />";
   }
   
   print OUT "