Forum

Thread tagged as: Question, Blog

Prevent upload of any image smaller than minimum size?

Hi there,

I have my image upload working well in my blog and is forcing a crop so all images are the same size if anyone should upload something too large. There is a minimum requirement for this which I have advised with help tags, however, I was wondering if there was a way of preventing upload of an image file that is smaller than a set size? I may well have missed this in the documentation so any push in the right direction would be helpful.

I guess whatever the fix, this would work across the board and not just in blog?

Many thanks

Gary Ward

Gary Ward 0 points

  • 5 years ago
Simon Clay

Simon Clay 127 points

Hi Gary,

It's not a feature that's available at the moment, but as Drew hints in this thread it may be something that's addressed in Perch 2.9

https://forum.grabaperch.com/forum/04-08-2016-image-cropping

Drew McLellan

Drew McLellan 2638 points
Perch Support

At the moment there's no way to prevent selection of an image that is smaller than the specified size. The size limits were designed to prevent big images blowing a page apart, which typically isn't an issue with smaller images.

Simon Clay

Simon Clay 127 points

Smaller images also break the page layout.

Hi both, thanks for the info. I think some help notes will have to suffice in this case.

Many thanks

Drew McLellan

Drew McLellan 2638 points
Perch Support

Simon: I'm not sure why you're trying to go to war with me over this.

Simon Clay

Simon Clay 127 points

Oh, I'm not at all. Please don't misunderstand. I genuinely find that images that are too small and don't get cropped at all are problematic.

Not wishing to interject, however, my site is set up in a way that if the user uploads an image that is too small, it still works and doesn't break the layout... it just doesn't look quite as aesthetically pleasing on the eye from a design POV.

It's just a little less pleasing than having images all the same size.

In my opinion, this is the clients look out to be certain that they adhere to the advice given in the help notes, if they wish for the site to look it's best.

I don't fully understand why smaller images are breaking your layout Simon as I've not had this issue.