[Koha-cvs] CVS: koha/tmpl opacmain.pl,1.1.2.3,1.1.2.4

Finlay Thompson finlayt at users.sourceforge.net
Thu Sep 12 06:23:27 CEST 2002


Update of /cvsroot/koha/koha/tmpl
In directory usw-pr-cvs1:/tmp/cvs-serv28981/tmpl

Modified Files:
      Tag: rel-1-2
	opacmain.pl 
Log Message:

uses the gettemplate method from Output.pm now. Has only ten lines :-)



Index: opacmain.pl
===================================================================
RCS file: /cvsroot/koha/koha/tmpl/Attic/opacmain.pl,v
retrieving revision 1.1.2.3
retrieving revision 1.1.2.4
diff -C2 -r1.1.2.3 -r1.1.2.4
*** opacmain.pl	11 Sep 2002 22:11:17 -0000	1.1.2.3
--- opacmain.pl	12 Sep 2002 04:23:25 -0000	1.1.2.4
***************
*** 1,24 ****
  #!/usr/bin/perl
- use HTML::Template;   # new Template
  use strict;
  require Exporter;
! use C4::Database;     # configfile
! use C4::Output;       # themelanguage
! use CGI;              # new CGI
  use C4::Auth;         # checkauth
  
  my $query = new CGI;
- #my ($loggedinuser, $cookie, $sessionID) = checkauth($query);
- 
- my $configfile = configfile();
- 
- my $htdocs = $configfile->{'opachtdocs'};
- 
- my $templatebase = "opac-main.tmpl";
  
! my ($theme, $lang) = themelanguage($htdocs, $templatebase);
  
! my $template = HTML::Template->new(filename => "$htdocs/$theme/$lang/$templatebase", die_on_bad_params => 0, path => ["$htdocs/includes"]);
  
- #$template->param(SITE_RESULTS => $sitearray);
  print "Content-Type: text/html\n\n", $template->output;
--- 1,15 ----
  #!/usr/bin/perl
  use strict;
  require Exporter;
! use CGI;
! 
! use C4::Output;       # gettemplate
  use C4::Auth;         # checkauth
  
  my $query = new CGI;
  
! my ($loggedinuser, $cookie, $sessionID) = checkauth($query, 1);
  
! my $template = gettemplate("opac-main.tmpl", "opac");
  
  print "Content-Type: text/html\n\n", $template->output;





More information about the Koha-cvs mailing list