first working version of hacked photo upload