recursively create parent dirs for file uploads
perform variable substitution on upload file paths