Bug 6923 : Fixing a bug introduced by 6755 - was blocking help being used or edited
authorChris Cormack <chrisc@catalyst.net.nz>
Mon, 26 Sep 2011 22:14:06 +0000 (11:14 +1300)
committerChris Cormack <chrisc@catalyst.net.nz>
Mon, 26 Sep 2011 22:14:06 +0000 (11:14 +1300)
edithelp.pl
help.pl

index 4d7e0c0..32db062 100755 (executable)
@@ -19,6 +19,7 @@
 
 use strict;
 use C4::Output;
+use C4::Templates;
 use C4::Auth;
 use CGI;
 use warnings;
@@ -66,7 +67,7 @@ sub _get_filepath ($;$) {
     $referer =~ /koha\/(.*)\.pl/;
     my $from = "help/$1.tt";
     my $htdocs = C4::Context->config('intrahtdocs');
-    my ($theme, $lang) = themelanguage( $htdocs, $from, "intranet", $input );
+    my ($theme, $lang) = C4::Templates::themelanguage( $htdocs, $from, "intranet", $input );
        $debug and print STDERR "help filepath: $htdocs/$theme/$lang/modules/$from";
        return "$htdocs/$theme/$lang/modules/$from";
 }
diff --git a/help.pl b/help.pl
index 7208a8a..69e8ab8 100755 (executable)
--- a/help.pl
+++ b/help.pl
@@ -35,10 +35,10 @@ $refer =~ /koha\/(.*)\.pl/;
 my $from = "modules/help/$1.tt";
 
 my $htdocs = C4::Context->config('intrahtdocs');
-my ( $theme, $lang ) = themelanguage( $htdocs, $from, "intranet", $query );
+my ( $theme, $lang ) = C4::Templates::themelanguage( $htdocs, $from, "intranet", $query );
 unless ( -e "$htdocs/$theme/$lang/$from" ) {
     $from = "modules/help/nohelp.tt";
-    ( $theme, $lang ) = themelanguage( $htdocs, $from, "intranet", $query );
+    ( $theme, $lang ) = C4::Templates::themelanguage( $htdocs, $from, "intranet", $query );
 }
 my $template = C4::Templates->new('intranet', "$htdocs/$theme/$lang/$from");
 $template->param( referer => $refer );