Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Simon Yohannes 58 posts 188 karma points
    Jan 23, 2019 @ 15:44
    Simon Yohannes
    0

    image cropper not cropping

    hi there,

    i'm running umbraco 7.13.1 with imageprocessor and imageprocessor.web nuget packages updated to v2.6.2.25 and v4.9.3.25 respectively.

    i'm also using FileSystemProviders.Azure (v1.0.3) to get all the media items into Azure blob storage.

    the issue i'm having is that the crop urls are generated but when i visit them i get the original sized image and not a crop. there's also nothing in the ~/app_data/cache folder being generated (that's where the crops normally live).

    here's an example url "/media/3212/card-room.jpg?crop=0.064634964078002149,0,0.73830721861101611,0.64967499144714358&cropmode=percentage&width=256&height=256&rnd=131927236610000000"

    there are no errors in the log file either

    can anybody help?

    thank you, Simon

  • Jan Skovgaard 11280 posts 23678 karma points MVP 11x admin c-trib
    Jan 23, 2019 @ 17:16
    Jan Skovgaard
    0

    Hi Simon

    Is this a fresh installation of 7.13.1 or have you been doing an upgrade? If it's an upgraded install, what version did you upgrade from?

    Also what does your code for calling the image cropper look like in your view? I have just skimmed the issue tracker and I have not seen any reported bugs about this issue and I imagine that if there was a bug it would have been reported by now - We have some upgraded sites where I have not heard about any issues using the cropper. But it's not some sites I have been working on myself so I don't know if it might be because people have simply just not noticed...

    Looking forward to hearing from you!

    /Jan

  • Simon Yohannes 58 posts 188 karma points
    Jan 23, 2019 @ 17:23
    Simon Yohannes
    0

    hi Jan,

    i upgraded from 7.12.3.

    i just installed a fresh copy of 7.13.1 and while i didn't check with filesystemproviders.azure installed it seems to crop as expected.

    in my actual project though, the cache folder doesn't even have any entries. i just changed back to the default filesystemprovider and it still doesn't crop.

    i'm using pretty standard code to get the crop url:

    var mItem = Umbraco.TypedMedia(5498);
    var cropUrl = mItem.GetCropUrl("shipGallery");
    

    cheers

  • Jan Skovgaard 11280 posts 23678 karma points MVP 11x admin c-trib
    Jan 23, 2019 @ 17:28
    Jan Skovgaard
    0

    Hi Simon

    Ok, so it's most likely something with the upgrade - I'll see if I can reproduce this issue of yours later tonight.

    Just some further questions - 7.12.3 was the initial version number, right? I mean you have not previously upgraded the site before ending on 7.12.3?

    The upgrade you did - Was it done using Nuget or manually? I have not checked if there was any notes about something one needed to be aware of and do manually after the upgrade, which could be the cause maybe? Some config's being overriden, which should not?

    Anyway I'll try doing a fresh 7.12.3 and see what happens when I upgrade to 7.13.1.

    /Jan

  • Simon Yohannes 58 posts 188 karma points
    Jan 23, 2019 @ 17:31
    Simon Yohannes
    0

    yes Jan 7.12.3 was the initial version. i upgraded using nuget and am also not aware of any manual editing that needed to be done after upgrading.

    cheers, Simon

  • Simon Yohannes 58 posts 188 karma points
    Jan 23, 2019 @ 18:06
    Simon Yohannes
    0

    ok so in my new 7.13.1 i pointed the connection string to my project db and installed the azure provider. it doesn't crop.

    if i change the filesystemprovider back to default it crops.

  • Jan Skovgaard 11280 posts 23678 karma points MVP 11x admin c-trib
    Jan 23, 2019 @ 18:10
    Jan Skovgaard
    1

    Hi Simon

    Hmm, ok - Then I'm afraid I'm not able to try and help you out any further since I'm not any good with Azure unfortunately. But at least you have made some progress - Now it's a matter of figuring out why it does not work with the azure provider. Wish I could provide more input - Fingers crossed that you manage to figure it out :-)

    /Jan

  • Simon Yohannes 58 posts 188 karma points
    Jan 23, 2019 @ 19:15
    Simon Yohannes
    0

    thanks Jan!

    if anybody else here has any experience please share

  • Simon Yohannes 58 posts 188 karma points
    Jan 23, 2019 @ 21:15
    Simon Yohannes
    103

    after downloading the imageprocessor source code and stepping through the ImageProcessingModule.cs i've found that image processor couldn't download the image from azure because the "secure transfer required" setting was enabled (by default) in my storage account and imageprocessor was trying to access the image via HTTP and not HTTPS (probably because i was browsing the site in HTTP).

    i've disabled "secure transfer required" in my storage account configuration and cropping now works.

    hope this helps somebody

  • Jan Skovgaard 11280 posts 23678 karma points MVP 11x admin c-trib
    Jan 23, 2019 @ 22:10
    Jan Skovgaard
    0

    Really happy to see you figured out the issue Simon :-) And thank you for sharing the solution - I'm sure it will be useful to someone at some point. H5YR!

    /Jan

  • Harry Spyrou 212 posts 604 karma points
    Jun 25, 2021 @ 14:01
    Harry Spyrou
    0

    It was :D

Please Sign in or register to post replies

Write your reply to:

Draft