This function is completly wrong:

function theme_image_inline_img($img) {
return l('Only local images are allowed.width || $img->height ? url("image/view/$img->nid", 'res=' . $img->width . "x$img->height") : "$base_url/$img->thumb_path") . '"' . ($img->width ? " width=\"$img->width\"" : '') . ($img->height ? " height=\"$img->height\"" : NULL) . ($img->align ? " align=\"$img->align\"" : '') . ($img->border ? " border=\"$img->border\"" : '') . ($img->hspace ? " hspace=\"$img->hspace\"" : '') . ($img->vspace ? " vspace=\"$img->vspace\"" : '') . " alt=\"$img->title\" />", "node/$img->nid");
}

Please give this a especial attention.

CommentFileSizeAuthor
#3 image_filter.module.diff2.51 KBaries

Comments

mrowe’s picture

Priority: Critical » Normal

Would you care to be a little more explicit about exactly how it is wrong, and what should be done to fix it?

aries’s picture

It's not the answer of the above, but I think the theme_ function should use CSS tags everywhere it can, because most of the themes using xHTML 1.0 or 1.1 strict, where these attributes like "align" or "vspace" are not present, and of course they are depend on the media type (eg. print, screen, etc.)

aries’s picture

StatusFileSize
new2.51 KB

Here's a patch. This is my first one, so it can be buggy =)

David Hull’s picture

If you use the "new"-style image code, you can write [image:nodeid class="classname"] (but there is currently no way to specify an inline style).

David Hull’s picture

Title: Thumb theme function error » Specify style information in image code for img tag
Category: bug » feature

Change title from "Thumb theme function error" to better describe what remains to be done.

David Hull’s picture

I added the ability to write [image:nodeid style="style data"] to image_filter in CVS.

Anonymous’s picture