bhakti_thakkar
12-11-2008, 06:43 AM
hi all,
I am using DOMPDF to generate certain reports. Its working fine. Below is the layout of my PDF
<html>
<body>
<Headers>
<Products>
<Production Units>
<Processing Units>
<footer>
</body>
</html>
this works fine. But there is a case come up where there is huge huge data. The Pdf goes up to 10 pages. The script gets execution time out problem when i try to render() the output in DOMPDF. if i print the buffer output just in PHP it works but with PDF its an issue.
I breaked the buffer output in chunks and take the output in different variables.
$html_3=ob_get_contents(); // $html_4 , 5 , 6 and so on
ob_end_clean(); // delete Output-Buffer
ob_start();
$html_L=ob_get_contents(); // last content of the page
// delete Output-Buffer
ob_end_clean();
$html=$html_1.$html_2.$html_3;
//$html.=$html_L;
//print $html;
but still i am having the same issue.
This is what i do for managing buffer and script time out for that page:
ini_set("memory_limit","850M");
set_time_limit('120');
So a conclusion lands up is the memory size of the variable. :eek: if i just print upto html_1 and html_2 its fine. but if i try to concate further its a problem.
So how can i handle this issue. Please Please help.
Thanks in anticipation
I am using DOMPDF to generate certain reports. Its working fine. Below is the layout of my PDF
<html>
<body>
<Headers>
<Products>
<Production Units>
<Processing Units>
<footer>
</body>
</html>
this works fine. But there is a case come up where there is huge huge data. The Pdf goes up to 10 pages. The script gets execution time out problem when i try to render() the output in DOMPDF. if i print the buffer output just in PHP it works but with PDF its an issue.
I breaked the buffer output in chunks and take the output in different variables.
$html_3=ob_get_contents(); // $html_4 , 5 , 6 and so on
ob_end_clean(); // delete Output-Buffer
ob_start();
$html_L=ob_get_contents(); // last content of the page
// delete Output-Buffer
ob_end_clean();
$html=$html_1.$html_2.$html_3;
//$html.=$html_L;
//print $html;
but still i am having the same issue.
This is what i do for managing buffer and script time out for that page:
ini_set("memory_limit","850M");
set_time_limit('120');
So a conclusion lands up is the memory size of the variable. :eek: if i just print upto html_1 and html_2 its fine. but if i try to concate further its a problem.
So how can i handle this issue. Please Please help.
Thanks in anticipation