Catalog image is coded to be able to work without imagecache.
However, it's not working.
The problem is here in theme_uc_catalog_browse:
if (!empty($catalog->image)) {
$output .= theme('imagecache', 'uc_thumbnail', $catalog->image['filepath'], $catalog->name, $catalog->name, array('class' => 'category'));
}
With no imagecache module, there's no theme_imagecache so we'll never get anything back from this.
There's a related but different problem on the term form:
$image_display = theme('image', $image->filename, t('Term image'));
Should be filepath, not filename.
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | catalog_no_imagecache.patch | 2.57 KB | Island Usurper |
| #3 | catalog_term_image_no_imagecache.patch | 873 bytes | sociotech |
| #2 | catalog_image_no_imagecache.patch | 926 bytes | sociotech |
Comments
Comment #1
rszrama commentedTagging.
Comment #2
sociotech commentedHere's a patch against 2.0-rc3 that should fix the first part of the issue (no image if imagecache is disabled). One caveat: you'll of course end up with the image at its original size, which will look awkward if it isn't sized appropriately ahead of time.
Comment #3
sociotech commentedAnd here's a patch for the second part of the issue.
Comment #4
Island Usurper commentedI think those are good changes, but they aren't really enough to address the issue. On a catalog page that doesn't display any products, none of the child category images are displayed without imagecache. I took a look at the code that was loading those images, and decided I was doing something kind of silly. If imagecache was enabled, I was loading the cached image, and then running that image through the preset actions again.
So here are your changes and mine altogether, and they are now committed.
Comment #6
MakeOnlineShop commentedHi,
My catalog photos are too big, can you tell me how to change their size to show more products on 1 page ?
Thanks.