X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fautohandler;h=bdea50534232e66a6d310e37b8ceae1e9b4a3f7f;hb=79f1e3f6d8172bbb4e85bc063f19ba0010c9253f;hp=a3f7eb0086db5a097cbdd7751c852aa965fb6473;hpb=673b9a458d9138523026963df6fa3b4683e09bae;p=freeside.git diff --git a/httemplate/autohandler b/httemplate/autohandler index a3f7eb008..bdea50534 100644 --- a/httemplate/autohandler +++ b/httemplate/autohandler @@ -9,7 +9,18 @@ if ( UNIVERSAL::can(dbh, 'sprintProfile') ) { if ( lc($r->content_type) eq 'text/html' ) { - $profile = '
'. encode_entities(dbh->sprintProfile()). + ## barely worth it, just in case someone tries to use profiling on a + ## non-RT install + #eval "use Text::Wrapper;"; + #die $@ if $@; + + my $wrapper = new Text::Wrapper( columns => 80 ); + my $text = dbh->sprintProfile(); + #my $text = $wrapper->wrap( dbh->sprintProfile() ); + $text =~ s/^/ /mg; + + $profile = ''; } @@ -19,3 +30,6 @@ if ( UNIVERSAL::can(dbh, 'sprintProfile') ) { s/(<\/BODY>[\s\n]*<\/HTML>[\s\n]*)$/$profile$1/i; %filter> +<%cleanup> + dbh->commit(); +%cleanup>'. + encode_entities( $text ). #"\n\n". &sprintAutoProfile(). ''; "\n\n". '