Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I am not experiencing this all the time but occasionally the first time that I view the node I am seeing the original image. Refresh the page and then I see the cropped image.
Has anyone else experienced this?
Comment | File | Size | Author |
---|---|---|---|
#3 | imagefield_crop-original_image-1483980-3.patch | 2.48 KB | nlisgo |
#2 | imagefield_crop-original_image-1483980-2.patch | 545 bytes | nlisgo |
Comments
Comment #1
nlisgo CreditAttribution: nlisgo commentedI can confirm that on some occasions the original image is being displayed when the post is being viewed for the first time. I think this may have something to do with the fact that the cropped image overwrites the original image and if the node is viewed before this action is done then we will see the original image.
Comment #2
nlisgo CreditAttribution: nlisgo commentedFixed. This was a caching issue. basically because the cropped image is stored using the same filename as the original image. Cache will inevitably return the original image sometimes. I get round this by changing the location of the cropped file.
Comment #3
nlisgo CreditAttribution: nlisgo commentedHere is an improved patch that renames the file for updates not just inserts.
Comment #4
Peter Feddo CreditAttribution: Peter Feddo commentedI applied the patch and can't seem to get the cropped image to display. The image that gets stored and rendered is the original uncropped version.
Comment #5
nlisgo CreditAttribution: nlisgo commentedI had set the version to be 7.x-2.x-dev but you have switched it to 7.x-1.0
Would you prefer that I prepare a patch for the 7.x-2.0 branch? I am not using the 7.x-1.0 branch.
Comment #6
akalam CreditAttribution: akalam commentedThanks for the patch !
I ported it to the 1.x branch
https://www.drupal.org/node/2412183
Comment #7
kcolwell CreditAttribution: kcolwell commentedI found that desarrollo2.0's patch was very helpful and should be rolled into the next update.
Ken Colwell
Comment #8
joetsuihk CreditAttribution: joetsuihk commentedHi @kcolwell, you mean you tested the patch for 1.x? do you mind go over https://www.drupal.org/node/2412183 and state you had tested that patch? I will commit that to 1.x dev if so.
Thanks.
Comment #10
ram4nd CreditAttribution: ram4nd as a volunteer commented