Hey there,
By using
print theme('imagecache', 'preset_name', $image[filepath]);
We get returned an img tag with the src set to the imagecache generated image.
Is there a way to return just the src, as plain text (not as part of an img tag)?
For example I just want to be able to access "/files/imagecache/presetname/imagename.jpg" (but it needs to know to generate the image if it hasn't already, like the theme function does).
Thanks a lot.
Comments
Comment #1
mason@thecodingdesigner.com commentedI don't know how to do exactly what you're saying, but you can use php to parse the imagecache output to get the url string.
Comment #2
jrefano commentedworks great, thanks!
Comment #3
jrefano commentedi have since found the correct way to do this, which im not sure why i didnt realize before. imagecache_create_url() returns the path to the image w/o the image tag.
Comment #4
volocuga commentedHad the same issue, look at this http://drupal.org/node/659610