[ome-devel] Premature end of script headers: omeis
gerhard
bi1825 at fh-weihenstephan.de
Thu Nov 24 14:45:27 GMT 2005
Hello,
the following problem isn't a real OME problem but maybe someone had the
same problem and can give me a hint.
I use the following request to import an image into omeis. The request
is written in QT(using the QT Http class).
QHttpRequestHeader header("POST","/cgi-bin/omeis");
header.setValue("Accept","*/*");
header.setValue("Content-Type", "multipart/form-data; boundary=--125282808721657");
header.setValue("Host", ip_address);
header.setValue("Pragma","no-cache");
header.setValue("Expect","100-continue");
QByteArray bytes;
bytes.append("--125282808721657\n");
bytes.append("Content-Disposition: form-data; name=\"Method\"\n");
bytes.append("\nUploadFile\n");
bytes.append("--125282808721657\n");
bytes.append("Content-Disposition: form-data; name=\"File\"; filename=\"1.tif\"\n");
bytes.append("Content-Type: application/octet-stream\n\n");
bytes.append(file.readAll());
file.close(); // the file is opened before
bytes.append("--125282808721657--");
http_requestID_imageImport = httpMain->request(header, bytes);
Everytime i send this request i get the following error: Premature end
of script headers: omeis
Thanks for your help
gerhard
More information about the ome-devel
mailing list