in reply to Premature end of script headers ?

Look a apache log file for catch your errors.
Maybe CGI Documentation or Tutorials will be useful for you.
      
--------------------------------
SV* sv_bless(SV* sv, HV* stash);