Fix for 418
[wip/koha-chris_n.git] / mainpage.pl
1 #!/usr/bin/perl
2 use HTML::Template;
3 use strict;
4 require Exporter;
5 use C4::Database;
6 use C4::Output;  # contains gettemplate
7 use C4::Interface::CGI::Output;
8 use CGI;
9 use C4::Auth;
10
11 my $query = new CGI;
12 my ($template, $loggedinuser, $cookie)
13     = get_template_and_user({template_name => "intranet-main.tmpl",
14                              query => $query,
15                              type => "intranet",
16                              authnotrequired => 0,
17                              flagsrequired => {parameters => 1},
18                              debug => 1,
19                              });
20
21 my $marc_p = C4::Context->boolean_preference("marc");
22 $template->param(NOTMARC => !$marc_p);
23
24 output_html_with_http_headers $query, $cookie, $template->output;