Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re^3: HTML::Template::Pro - Issue with template files larger than 8K

by Uniden (Initiate)
on Jul 11, 2014 at 16:46 UTC ( [id://1093251]=note: print w/replies, xml ) Need Help??


in reply to Re^2: HTML::Template::Pro - Issue with template files larger than 8K
in thread HTML::Template::Pro - Issue with template files larger than 8K

Oki Doki! The culprit is the output buffering. When executing the script via command line, the header does display exactly after 8192 bytes, which when run through Apache produces an error. Output buffering can be disabled in Perl, so I added the line "$|=1;" to my script and now it works.

#!/usr/bin/perl
use strict;
$|=1;
use HTML::Template::Pro;
my $tmpl = HTML::Template::Pro -> new(filename => 'test.tmpl');
print "Content-Type: text/html\n\n";
$tmpl -> output();
  • Comment on Re^3: HTML::Template::Pro - Issue with template files larger than 8K

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1093251]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others learning in the Monastery: (5)
As of 2024-04-19 23:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found