Index: trunk/xpressme_integration_kit/class/modInfo_class.php
===================================================================
--- trunk/xpressme_integration_kit/class/modInfo_class.php	(revision 776)
+++ trunk/xpressme_integration_kit/class/modInfo_class.php	(revision 780)
@@ -50,10 +50,15 @@
     function modInfoClass()	//for PHP4 constructor
     {  
-    	global $xoopsModule,$wpConfigInfo;
-    	if (is_object($wpConfigInfo)){
+    	global $xoopsModule,$wpConfigInfo,$xoopsConfig;
+    	if (!is_object($wpConfigInfo)){
     		include_once dirname(__FILE__).'/wpConfigInfo_class.php';
     		$this->wpConfigInfo = new wpConfigInfoClass;
     	}
-		$this->xoops_root_path = XOOPS_ROOT_PATH;
+    	if (! is_object($xoopsModule)){
+			$module_handler =& xoops_gethandler('module');
+			$xoopsModule =& $module_handler->getByDirname(basename(dirname(dirname(__FILE__))));
+		}	
+
+    	$this->xoops_root_path = XOOPS_ROOT_PATH;
 		$this->xoops_trust_path = (defined('XOOPS_TRUST_PATH')) ? XOOPS_TRUST_PATH : '';
 		$this->xoops_url = XOOPS_URL;
@@ -78,6 +83,7 @@
 		if (function_exists('date_default_timezone_get')){
 			$this->xoops_time_zone = date_default_timezone_get();
-		}
-
+		} else {
+			$this->xoops_time_zone = $xoopsConfig['default_TZ'];
+		}
     }
 
@@ -230,6 +236,7 @@
 		$module =& $module_handler->getByDirname($dir_name);
 		$module_id = $module->getVar('mid');
-	}
-	
+		return $module_id;
+	}
+
 	function get_moduleID(){
 		global $xoopsModule;
