Check file type when upload - if JPEG do image process if PDF extension do not do the image processing
Upload a file to the server. I allow .pdf,.PDF.jpg,.png,.jpeg,.JPG,.PNG,.JPEG
When its an image … it must LOAD the and crop them as its doing… so that is sorted and working.
But i want to add a condition that if the file extension is PDF it must void the image processing.
Anybody that might have an idea… or add a condition to check the POST … eg… the file extension maybe
Can anybody point me in the correct direction please.
I have tried this… . condition… upload1.type != ‘.pdf’ then to only use the image processing…
also just tried upload1.type != ‘pdf’
but if i try a .pdf… the condition does not stop the image processor…
Community Page
Last updated:
Last updated: