0

In Drupal 6 there is a parameter $destination for the function 'image_scale_and_crop()' . The parameter is not available in D7. I have the following code block.

image_scale_and_crop($image, 100, 70);

This code is executed an the thumbnail is created in a path if I examine the file directory.

My question is, how I can determine the path where the cropped file is created in order to save it to db.

2

Maybe it's better to use an image style and use theme_image_style($variables)

|improve this answer|||||
  • I agree. See also drupal.stackexchange.com/q/17179/226. – marcvangend Dec 13 '11 at 10:07
  • I agree with you that it is possible to create an image style and use it. But in my case, I have to use the re-sizing, explicitly from the image_style because image size will be taken from database according to user assigned values. – Muneer Dec 13 '11 at 12:28
0

not sure if this is the link to answer your question http://api.drupal.org/api/drupal/includes--image.inc/function/image_save/7

|improve this answer|||||
0

Thanksfully I could find the answer. After using this function,, I have to say drupal..

image_save($image);

It was due to insufficient information in the documentation.

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.