# Suite 330, Boston, MA 02111-1307 USA
use strict;
+use C4::Auth;
use CGI;
use C4::Context;
use HTML::Template;
newauthority($dbh,$category,$insert,$insert,'',1,'');
$search_string=$insert;
}
-
-my $template = gettemplate("thesaurus_popup.tmpl",0);
+my ($template, $loggedinuser, $cookie)
+ = get_template_and_user({template_name => "thesaurus_popup.tmpl",
+ query => $input,
+ type => "intranet",
+ authnotrequired => 0,
+ flagsrequired => {parameters => 1},
+ debug => 1,
+ });
# /search thesaurus terms starting by search_string
my @freelib;
my %stdlib;
category => $category,
index => $index
);
-print "Content-Type: text/html\n\n", $template->output;
+print $input->header(-cookie => $cookie),$template->output;