#272: JSON encode file upload from PHP to Python

Resolves #272.