I need a script developed that enables a user to upload, crop, and? store a? profile picture.
The script must:
1. Allow the user to jpg pictures of all sizes.
2. Resize the picture initially so that it fits on the screen to be cropped by the user (enlarges or reduces image so that it can be cropped).
3. Enable the user to select the area to be cropped via dragging a box that can be resized, but must conform to a predefined ratio.
4. Upon making the selection, the user should click a button to save the cropped area. The image should then be stored in a profile picture folder titled with the ID of the user.
## Deliverables
We currently have a script that accomplishes this and generally? works fine, although has some trouble handling large images and is sometimes unreliable. The source code is attached. Each user is identified via a "authmid" session variable. This is how to determine the file name to store the cropped picture as.