I want to send the data in an XML form to Europass Web service to get Europass CV or Language portfolio as file - then I want to serve that file instantly (I don't want to write it on server's disk). Is it possible with serve_file() function?
I'd try calling the serve_file() function from htdocs/lib/file.php which will set those headers for you, and also make sure your pieform submit function calls $form->reply(PIEFORM_OK, 'some string').
You might also want to look at the code that serves up the export file (htdocs/export/index.php, htdocs/export/download.php). It's probably a bit more elaborate than you need (it displays a progress bar in an iframe) but it will give you an idea.
]]>header('Content-type: application/msword');
header('Content-Disposition: attachment; filename=cv.doc');
but then the statement
$form->json_reply(PIEFORM_OK, 'some string');
doesn't get executed (I think?!?). So on the left upper corner it says "Loading..." and the Submit button has a label "Processing..."
What should I do, to make this function to finish or to make these labels to disapear?
Help, please!