You have chosen to sponsor your bid up to a maximum amount of .
This project involves editing the my_profile.php file attached, which is based on the tables 'members' , 'tbl_badges' and 'tbl_badges_acquired'. Dumps attached.
Task 1 - Profile editing.
The form1 section of my_profile.php needs to be altered so that users can:
(a) - change their profile pic or upload a new one. I'll await advice from you on how best to ensure that no dangerous files can NOT be uploaded.
The upload path is images/member_avatars. In order to circumvent the problem of different users uploading an avatar with the same name (eg: avatar.jpg), I'd like the upload date appended to the file name with some sort of code like this
$AVATAR_FILE_NAME = $EXPLODED_STRING.$TODAY_DATE_AND_TIME.".".$EXPLODED_STRING;
.so avatar.jpg would end up being avatar2013.02.22.16.56.31.jpg or somesuch, depending on the date / time of upload.
Note: The code is already in place to show a default avatar if the avatar field is blank. Keep that code.
Note 2: Avatars need to be square. If a user uploads an avatar which is not square it needs to be cropped.
If it is bigger than 250px by 250px and square, it can be sized down without cropping & displayed at 250px by 250px
If it is bigger than 250px by 250px, and not square, it can be sized down to 250px on one side and cropped on the other.
If it is smaller than 250px ... I'll listen and discuss what to do here.
(b) - Change their password
(member_password and member_password confirm fields are already set up. These must match and member_password must be updated in the members table if they match.
Minimum 5 characters.
Please find files attached in zip.