CodeCharge Studio
search Register Login  

Web Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> PHP

 Saving template results in a file

Print topic Send  topic

Author Message
FRAMIREZS

Posts: 6
Posted: 02/25/2004, 10:26 AM


Is it possible save a template parse results into a file using $Tpl variable?
Then I want to use this html file for generating a pdf file with a external program (HTMLDOC)
And finally redirect the page to that pdf file.

I resolve this problem using smarty but I would like to integrate the code with CCS using CCS templates

Thanks

View profile  Send private message
peterr


Posts: 5971
Posted: 02/25/2004, 12:09 PM

For general info see http://forums.codecharge.com/posts.php?post_id=25411

In PHP the same could be done by replacing
$Tpl->PParse("main", false);

with
$Tpl->Parse("main", false);
$myVar = $Tpl->getvar("main");
print $myVar;

or use PHP output buffering features (http://www.php.net/manual/en/ref.outcontrol.php) in "Before Unload" page event :
function page_InitializeView() {
ob_start(); // enable buffering
}

function page_beforeunload() {
$myVar = ob_get_contents(); // get buffer content
}

_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

PHP Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.