form.addPart("path", new StringBody(path, Charset.forName("UTF-8")));
form.addPart("action", new StringBody("0")); // FancyFileUpload.ACTION_INSERT
HttpPost post = new HttpPost(url + "/frontend/FileUpload;jsessionid=" + token);
post.setHeader("Cookie", "jsessionid=" + token);
post.setEntity(form);
ResponseHandler<String> responseHandler = new BasicResponseHandler();
response = client.execute(post, responseHandler);
} else {
// Store in disk
String home = System.getProperty("user.home");
File dst = new File(home, tmpFile.getName());