Prestashop: Correct File Permissions

I noticed, after uploading Prestashop to my webserver and extracting the files, I was getting 500 Internal Server errors. After a bit of testing I figured out the file permissions from having extracted the files were actually incorrect. Directories need to be set at 755 while files should be set at 644.

To save time, I SSH'd into the server and ran these commands after navigating to the public_html folder (or www folder):

chown www-data:www-data  -R *
find . -type d -exec chmod 755 {} \;
find . -type f -exec chmod 644 {} \;

That should assign the correct user to the files, and permissions as well.