]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/blobdiff - IkiWiki/Plugin/img.pm
(no commit message)
[git.ikiwiki.info.git] / IkiWiki / Plugin / img.pm
index eb1b6812482dab4065f40dbe6b8a4ebc96726a49..103f6b2b3510067f10a5eddf86f8e657ba96fe29 100644 (file)
@@ -152,8 +152,12 @@ sub preprocess (@) {
                $imgurl=urlto($imglink, $params{destpage});
        }
        else {
-               $fileurl="$config{url}/$file";
-               $imgurl="$config{url}/$imglink";
+               $fileurl=urlto($file);
+               $imgurl=urlto($imglink);
+       }
+
+       if (! exists $params{class}) {
+               $params{class}="img";
        }
 
        my $attrs='';