media upload, flexible ajax