Snapr is our clone of the image posting site Flickr! You are able to upload images, comment, and create your profile.
- Live Link: snapr
- The landing page is the first page the user will see when they arrive at the site. You are able to click the start for free button or the log in/ sign up button in the top right corner.
- The log in page is where existing users can log in. If you don't have an account you may click the 'Sign up here' and you will be directed to the sign up page. Also if you don't want to create an account, you can use the demo user, which is an already created account.
- This is where you are able to see all users images. By clicking on their name it will take you to their profile. You can also like the photo at the star in the bottom right corner. In addition, clicking on the photo will take you to the single image page.
- On this page, if it isn't your photo, you are able to comment as well as favorite the photo. If you posted the photo, you are able to favorite, comment on, update, and delete the photo. Once you post a comment, you are then able to edit or delete the comment.
- Here you can create and update your profile. We have a section to write about yourself, a place to showcase photos you have uploaded, and a place for socials.
def get_unique_filename(filename):
ext = filename.rsplit(".", 1)[1].lower()
unique_filename = uuid.uuid4().hex
return f"{unique_filename}.{ext}"
def upload_file_to_s3(file, acl="public-read"):
try:
s3.upload_fileobj(
file,
BUCKET_NAME,
file.filename,
ExtraArgs={
"ACL": acl,
"ContentType": file.content_type
}
)
except Exception as e:
return {"errors": str(e)}
return {"url": f"{S3_LOCATION}{file.filename}"}
- get_unique_filename(filename): This helper function generates a unique and random UUID (Universally Unique Identifier) filename using Python "uuid" module.
- upload_file_to_s3(file, acl="public-read"): This function uploads the selected file to the assigned AWS (Amazon Web Service) S3 bucket and returns a URL when the file is successfully uploaded. It also returns an error statement if the upload fails.
- Ben Lee: https://www.linkedin.com/in/benkalee/
- Isaiah Barrett: https://www.linkedin.com/in/isaiah-barrett1/
- Jehan Ibrahem: https://www.linkedin.com/in/jehan-ibrahem/
- Leslie Chou: https://www.linkedin.com/in/lesliechou921/












