Warning: session_start(): open(/var/lib/php/sessions/sess_mp8f6j6efjdqjuvi4093aac1hq, O_RDWR) failed: No space left on device (28) in /var/www/tb-usercake/models/config.php on line 51
Warning: session_start(): Failed to read session data: files (path: /var/lib/php/sessions) in /var/www/tb-usercake/models/config.php on line 51
sS uploadToFileServerWithFixedID(File f, S name, S snippetID) {
ret uploadToFileServerWithFixedID(loadBinaryFile(f), name, snippetID);
}
sS uploadToFileServerWithFixedID(byte[] data, S name, S snippetID) {
print("Uploading " + l(data) + " bytes (" + quote(name) + ") to file server with id " + fsI(snippetID));
S page = postPage("http://butter.botcompany.de:8080/files/upload", "data", bytesToHex(data), "name", name, "id", psI(snippetID), '_pass, muricaPassword());
print(page);
Matcher m = Pattern.compile("/raw/([0-9]+)").matcher(page);
if (!m.find()) fail("File server said: " + page);
S url = "http://butter.botcompany.de:8080/files/" + m.group(1);
infoBox("Uploaded: " + url);
ret url;
}