I need to include an imagecache preset of an image in a form that is being created in a module.The image is a cck imagefield. There are two array elements in the cck information in the node containing name information. 'filename' is incorrect, because it lacks the _0 suffix that was appended to the physical file. 'filepath' contains the correct file name, but would require me manipulating the path to insert the imagecache path. I can do that, but wonder if I'm missing a more streamlined method.
Hi Jeff, If you want the path: http://api.lullabot.com/imagecache_create_path If you want the URL: http://api.lullabot.com/imagecache_create_url Regards Steven Jones ComputerMinds ltd - Perfect Drupal Websites Phone : 024 7666 7277 Mobile : 07702 131 576 Twitter : darthsteven http://www.computerminds.co.uk On 10 August 2010 16:22, Jeff Greenberg <jeff@ayendesigns.com> wrote:
I need to include an imagecache preset of an image in a form that is being created in a module.The image is a cck imagefield. There are two array elements in the cck information in the node containing name information.
'filename' is incorrect, because it lacks the _0 suffix that was appended to the physical file.
'filepath' contains the correct file name, but would require me manipulating the path to insert the imagecache path. I can do that, but wonder if I'm missing a more streamlined method.
Jeff You can call imagecache_create_url($preset_name, $filepath) Nevets On 8/10/2010 10:22 AM, Jeff Greenberg wrote:
I need to include an imagecache preset of an image in a form that is being created in a module.The image is a cck imagefield. There are two array elements in the cck information in the node containing name information.
'filename' is incorrect, because it lacks the _0 suffix that was appended to the physical file.
'filepath' contains the correct file name, but would require me manipulating the path to insert the imagecache path. I can do that, but wonder if I'm missing a more streamlined method.
participants (3)
-
Jeff Greenberg -
Steve Ringwood -
Steven Jones