updated the PHP scripts to detect image dimensions and populate the UI
started writing logic to adjust dimensions while keeping aspect ratio, but for some reason the calculations don't seem to work when combined together (resizing based on exceeding both width and height maximums)
PLAN: detect actual viewport size via Javascript and determine maximums based on that
Actual: ~13h