mvolke Posted November 4, 2013 Share Posted November 4, 2013 I discovered that if I create two thumbnails with the same size but different additional settings only one file (the first setting) is created because the settings are not reflected in the filename. E.g. $image->size(200, 100, array('cropping' => false)); $image->size(200, 100, array('cropping' => true)); In this case the second image won't be cropped. I would expect that two different thumbnail will be generated. Link to comment Share on other sites More sharing options...
ryan Posted November 8, 2013 Share Posted November 8, 2013 There really isn't much point in a cropping=false value to this particular call, because that would force a stretched image... something that there is almost never a practical use for. You'd be better off just specifying only a width or height, to ensure you don't get a stretched image. But you are correct in that for the most part, ProcessWire only maintains one thumbnail per dimension. There is one exception: if you specify details about where it should crop, it should keep separate copies, i.e. $img1 = $image->size(200, 100, array("cropping" => "center")); $img2 = $image->size(200, 100, array("cropping" => "northwest")); 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now