By: Florin
Date: 2013-02-07
Time: 00:55
|
OPENTBS_FILE + OPENTBS_DOWNLOAD
Hello,
I create a docx file with OpenTBS which I would like to save on the disk and send to download.
Something like this :
$tbs->Show(OPENTBS_FILE, $filename);
$tbs->Show(OPENTBS_DOWNLOAD, $filename);
or
$tbs->Show(OPENTBS_FILE+OPENTBS_DOWNLOAD, $filename);
Doing this creates a valid docx file on the disk, but the one generated to download is corrupted.
Is it possible to achieve this result? I'm using OpenTBS 1.7.6.
Thank you.
|
By: Skrol29
Date: 2013-02-07
Time: 21:43
|
Re: OPENTBS_FILE + OPENTBS_DOWNLOAD
Hi,
The TBS object cannot be rendered twice with OpenTBS.
Since you have used ->Show(), it is over.
So you have to save it on the disk with $tbs->Show(OPENTBS_FILE, $filename)
and then you can perform yourself the download of this new file using a tiny snippet of code.
|
By: Florin
Date: 2013-02-08
Time: 00:51
|
Re: OPENTBS_FILE + OPENTBS_DOWNLOAD
Thank you for your answer.
I'll do it manually, no problem.
And thank you for this great program!
|
|
Posting in progress.
Please wait...
|