[vhffs-dev] [568] Fixed a bug which prevented js to be included if themes path wasn' t ending with a /.

[ Thread Index | Date Index | More vhffs.org/vhffs-dev Archives ]


Revision: 568
Author:   beuss
Date:     2007-04-16 17:09:39 +0000 (Mon, 16 Apr 2007)

Log Message:
-----------
Fixed a bug which prevented js to be included if themes path wasn't ending with a /.

Modified Paths:
--------------
    trunk/vhffs-api/src/Vhffs/Panel/Main.pm


Modified: trunk/vhffs-api/src/Vhffs/Panel/Main.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Panel/Main.pm	2007-04-16 16:40:11 UTC (rev 567)
+++ trunk/vhffs-api/src/Vhffs/Panel/Main.pm	2007-04-16 17:09:39 UTC (rev 568)
@@ -11,6 +11,7 @@
 use Locale::gettext;
 use CGI;
 use CGI::Session;
+use File::Spec;
 use strict;
 
 use Vhffs::Main;
@@ -288,7 +289,8 @@
 	$maintemplate->param( THEME => $theme );
 
     # Allows each theme to have its own Jscripts
-    my $jsglob = $config->get_themesdir()."$theme/js/*.js";
+
+    my $jsglob = File::Spec->catfile($config->get_themesdir(), $theme, '/js/*.js');
     my $jswebpath = "/themes/$theme/js/";
     my @jscripts;
     push @jscripts, {SCRIPT => '/js/commons.js'};


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/