Ibrahim Azhar Armar
Ibrahim Azhar Armar

Reputation: 25755

Is it possible to limit the user to upload an image with fixed dimension?

Is there any Jquery Plugin to perform the image dimension operation on an image before being uploaded using uplodify. i want the plugin to check the image dimension with the fixed define size and then only process for uploading.

right now i am doing it with PHP function, instead of server side validation i want to adopt the client side validation.

Upvotes: 1

Views: 195

Answers (2)

D.J
D.J

Reputation: 2534

Have you considered any other alternatives?

I have similar problem as you do, though i am using asp.net C#

this is my solution:

  1. of course, obvious user guidance of the image uploading control
  2. use server end image thumbnail facility, automatically resize the image into the right size that your system required.
  3. display result preview for user doing final review after upload.

it is ideal to check in client end first, however JS may causing compatibility issue. secondly, always check on server end, since client end is not always reliable.

Upvotes: 0

jwueller
jwueller

Reputation: 30996

I do not believe that this is possible, since JavaScript is not allowed to access the local filesystem (for security reasons).

Upvotes: 1

Related Questions