[Koha] Urgent 2.2.6 to 2.2.9 upgrade help

Rick Welykochy rick at praxis.com.au
Thu Sep 4 17:14:20 NZST 2008


hammondthrasher_c at usp.ac.fj wrote:

> The error log reports that circulation.pl, memberentry.pl, and moremember.pl get
> "Premature end of script headers". Which reminds me of when I write perl cgis on
> Windows and then load them on a linux server without fixing the line feeds. It
> is possible that other scripts have this problem as well.

The "Premature end of script headers" often occurs at the beginning of
script execution before the perl script hsa had a chance to output the
HTTP headers. Thus, the CGI complains that no headres have been output.

You can make a small tweak to the perl scripts in question so that any
errors that occur are trapped and output to your browser.

Manually in an editor, where you see this:

    use CGI;

and a line thereafter:

    use CGI::Carp qw(fatalsToBrowser);

Or if you are brave, you can add this line automatically to all scripts
in Koha:


    cd /usr/local/koha
    find . -wholename *cgi-bin/*.pl -exec sed '-i~' \
	-e 's|use CGI|use CGI::Carp qw(fatalsToBrowser); use CGI|' {} \;

(The last two lines are one command-line, but I've split it so it is
  more readable in email.)


HTH!

cheers
rickw


-- 
________________________________________________________________
Rick Welykochy || Praxis Services || Internet Driving Instructor

Do you realise that in forty years we'll have thousands of old ladies
running around with tattoos and rap music will be the golden oldies?
       -- Maxine



More information about the Koha mailing list