--- ezjscserverfunctionsjs.php.orig	2011-01-26 15:07:37.000000000 +0100
+++ ezjscserverfunctionsjs.php.new	2011-01-26 15:13:55.000000000 +0100
@@ -13,12 +13,12 @@
 //   This program is free software; you can redistribute it and/or
 //   modify it under the terms of version 2.0  of the GNU General
 //   Public License as published by the Free Software Foundation.
-// 
+//
 //   This program is distributed in the hope that it will be useful,
 //    but WITHOUT ANY WARRANTY; without even the implied warranty of
 //   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 //   GNU General Public License for more details.
-// 
+//
 //   You should have received a copy of version 2.0 of the GNU General
 //   Public License along with this program; if not, write to the Free
 //   Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
@@ -110,7 +110,7 @@
         {
             $scriptFiles = $ezjscoreIni->variable( 'eZJSCore', 'LocalScripts' );
             $scriptBases = $ezjscoreIni->variable( 'eZJSCore', 'LocalScriptBasePath' );
-            $packerFiles = array_merge( array( $scriptFiles['yui3'], 'ezjsc::yui3conf::' . $scriptBases['yui3'] ), $packerFiles );
+            $packerFiles = array_merge( array( $scriptFiles['yui3'], "ezjsc::yui3conf::{$scriptBases['yui3']}::{$scriptBases['yui2']}" ), $packerFiles );
         }
         return '';
     }
@@ -118,13 +118,16 @@
     /**
      * Yui3 config as requested by {@link ezjscServerFunctionsJs::yui3()}
      *
-     * @param array $args First value is base bath if set
+     * @param array $args First value is base path for yui3 and yui2 (for yui 2in3 setup)
      * @return string YUI 3.0 JavaScript config string
      */
     public static function yui3conf( $args )
     {
-        if ( isset( $args[0] ) )
-            return 'var YUI3_config = { \'base\' : \'' . self::getDesignFile( $args[0] ) . '\', modules: {} };';
+        if ( isset( $args[1] ) )
+        {
+            return "var YUI3_config = { 'base': '" . self::getDesignFile( $args[0] ) . "', 'modules': {}," .
+                    " 'groups': { 'yui2': { 'base': '" . self::getDesignFile( $args[1] ) . "' } } };";
+        }
 
         return 'var YUI3_config = { modules: {} };';
     }
