Merge commit 'origin/core-1.0.0' into core
[platal.git] / plugins / compiler.javascript.php
index b17d370..597d95b 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /***************************************************************************
- *  Copyright (C) 2003-2008 Polytechnique.org                              *
+ *  Copyright (C) 2003-2009 Polytechnique.org                              *
  *  http://opensource.polytechnique.org/                                   *
  *                                                                         *
  *  This program is free software; you can redistribute it and/or modify   *
@@ -18,7 +18,6 @@
  *  Foundation, Inc.,                                                      *
  *  59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                *
  ***************************************************************************/
-require_once 'platal.inc.php';
 
 function smarty_compiler_javascript($tag_attrs, &$compiler)
 {
@@ -29,7 +28,7 @@ function smarty_compiler_javascript($tag_attrs, &$compiler)
     }
     $name = pl_entities(trim($name, '\'"'), ENT_QUOTES);
     $name = "javascript/$name.js";
-    if ($full) {
+    if (isset($full) && $full) {
         global $globals;
         $name = $globals->baseurl . '/' . $name;
     }