Index: branches/Ver3.0/xpressme_integration_kit/admin/help/wp_install_help.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/admin/help/wp_install_help.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/admin/help/wp_install_help.php	(revision 757)
@@ -1,40 +1,112 @@
 <?php
+	function text_indent($text,$num = 1,$css_option='')
+	{
+		$ret = '';
+		$px = 24 * $num;
+		$ret = '<div style="padding-left:' .$px .'px;'.$css_option.'">';
+		$ret .= $text . '</div>';
+		return $ret;
+	}
+
+	function get_download_info($locale='')
+	{
+		global $modInfo;
+		$local_package = '';
+		$mysql_version = preg_replace('/[^0-9.].*/', '', $modInfo->get_mysql_version());
+		$php_version = $modInfo->get_php_version();
+
+		if (empty($locale)) $locale = $modInfo->get_wpLang();
+
+/* test		
+		$mysql_version='4.0.27';
+		$php_version = '4.1.1';
+*/
+		// wprdpress original option
+		// ?version=$wp_version&php=$php_version&locale=$locale&mysql=$mysql_version&local_package=$local_package";
+		$option = "?php=$php_version&locale=$locale&mysql=$mysql_version&local_package=$local_package";
+		$url = "http://api.wordpress.org/core/version-check/1.5/" .$option;
+		$handle = @fopen($url,'r');
+		if ($handle) {
+			$ans = array();
+			$num = 0;
+			$pos = 0;
+	    	while (($buffer = fgets($handle, 4096)) !== false) {
+	    		$buffer = trim($buffer);
+	    		if (strlen($buffer) == 0) {
+	    			$num++;
+	    			$pos=0;
+	    		} else {
+	    			$ans[$num][$pos] = $buffer;
+	    			$pos++;
+	    		}
+	    	}
+	    	if (!feof($handle)) {
+	        	echo "Error: unexpected fgets() fail\n";
+	    	}
+	    	fclose($handle);
+		}
+		$ressponce = $ans[0][0];
+		$site_url = $ans[0][1];
+		$download_url = $ans[0][2];
+		$wp_version = $ans[0][3];
+		$download_lang = $ans[0][4];
+//		print_r($ans);
+		if (isset($ans[1])){
+			$en_download_url = $ans[1][2];
+		}
+		$ret = text_indent('(Check URL: '.$url.')',3);
+		if ($locale == $download_lang){
+			$ret .= text_indent(sprintf(_AM_XP2_WP_INFO_1,$locale),2);
+			$ret .= text_indent('<a href="'.$download_url.'">' . $download_url .'</a>' ,3);
+			if (!empty($en_download_url)){
+				$ret .= text_indent(_AM_XP2_WP_INFO_4,2);
+				$ret .= text_indent('<a href="'.$en_download_url .'">' . $en_download_url .'</a>' ,3);
+			}
+		} else {
+			$ret .= text_indent(sprintf(_AM_XP2_WP_INFO_2,$locale));
+			$ret .= text_indent(_AM_XP2_WP_INFO_3,2);
+			$ret .= text_indent('<a href="http://codex.wordpress.org/WordPress_in_Your_Language" target="	_blank">WordPress_in_Your_Language</a>' ,3);
+			$ret .= text_indent(_AM_XP2_WP_INFO_4,2);
+			$ret .= text_indent('<a href="'.$download_url.'">' . $download_url .'</a>' ,3);
+		}
+		echo $ret;
+	}
+}
+	
 	function wp_install_guide(){
+		global $modInfo;
 		$mydirpath = dirname( dirname( dirname( __FILE__ ) ) ) ;
 		$mydirname = basename(dirname( dirname( dirname( __FILE__ ) ) )) ;
-		include_once $mydirpath . '/class/wpInfo_class.php';
 		$xoops_lang = @$GLOBALS["xoopsConfig"]['language'];
-		$wp_info = new wpInfo;
-		$wp_lang = $wp_info->get_wpLang($xoops_lang);
-		if (!$wp_info->is_wp_file_found()){
+		if (!$modInfo->is_wp_file_found()){
 			//Download
-			echo $wp_info->get_mod_image_link('check_bad_s.png');
+			echo $modInfo->get_mod_image_link('check_bad_s.png');
 			echo '<font size="4" >'._AM_XP2_WP_CHK_0 .'</font><br />';
 			echo '<br />';
-			echo $wp_info->text_indent(_AM_XP2_WP_CHK_1 . _AM_XP2_WP_CHK_2);
+			echo text_indent(_AM_XP2_WP_CHK_1 . _AM_XP2_WP_CHK_2);
 			echo '<br />';
-			echo $wp_info->text_indent(_AM_XP2_WP_STEP_1,1,'font-weight:bold;');
-			echo $wp_info->get_download_info('ja');
+			echo text_indent(_AM_XP2_WP_STEP_1,1,'font-weight:bold;');
+			echo get_download_info('ja');
 			echo '<br />';
 			// Uncompress
-			echo $wp_info->text_indent(_AM_XP2_WP_STEP_2,1,'font-weight:bold;');
-			echo $wp_info->text_indent(_AM_XP2_WP_INFO_5,2);			
+			echo text_indent(_AM_XP2_WP_STEP_2,1,'font-weight:bold;');
+			echo text_indent(_AM_XP2_WP_INFO_5,2);			
 			echo '<br />';
-			echo '<div style="padding-left:60px;">'.$wp_info->get_mod_image_link('wp_uncompless.png') . '</div>';
+			echo '<div style="padding-left:60px;">'.$modInfo->get_mod_image_link('wp_uncompless.png') . '</div>';
 			echo '<br />';
 			// Upload Wordpress
-			echo $wp_info->text_indent(_AM_XP2_WP_STEP_3,1,'font-weight:bold;');
-			printf($wp_info->text_indent(_AM_XP2_WP_INFO_6,2),$mydirname);			
-			printf($wp_info->text_indent(_AM_XP2_WP_INFO_7,3),$mydirpath);			
-			echo $wp_info->text_indent(_AM_XP2_WP_INFO_8,2);
+			echo text_indent(_AM_XP2_WP_STEP_3,1,'font-weight:bold;');
+			printf(text_indent(_AM_XP2_WP_INFO_6,2),$mydirname);			
+			printf(text_indent(_AM_XP2_WP_INFO_7,3),$mydirpath);			
+			echo text_indent(_AM_XP2_WP_INFO_8,2);
 			echo '<br />';
-			echo '<div style="padding-left:60px;">'.$wp_info->get_mod_image_link('wp_upload.png') . '</div>';
+			echo '<div style="padding-left:60px;">'.$modInfo->get_mod_image_link('wp_upload.png') . '</div>';
 			echo '<br />';
 			//Install
-			echo $wp_info->text_indent(_AM_XP2_WP_STEP_4,1,'font-weight:bold;');
-			echo $wp_info->text_indent(_AM_XP2_WP_INFO_9,2);			
+			echo text_indent(_AM_XP2_WP_STEP_4,1,'font-weight:bold;');
+			echo text_indent(_AM_XP2_WP_INFO_9,2);			
 
 		} else {
-			echo $wp_info->get_mod_image_link('check_good_s.png');
+			echo $modInfo->get_mod_image_link('check_good_s.png');
 			echo '<font size="4" >'._AM_XP2_WP_CHK_0 .'</font><br />';
 			echo '<br />';
Index: branches/Ver3.0/xpressme_integration_kit/admin/index.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/admin/index.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/admin/index.php	(revision 757)
@@ -319,217 +319,4 @@
 
 
-function xpress_config_report_view()
-{
-	require_once dirname(dirname( __FILE__ )).'/class/config_from_xoops.class.php' ;
-	$xoops_config = new ConfigFromXoops;
-	echo 'XOOPS_ROOT_PATH:  ' ; 
-	if(XOOPS_ROOT_PATH !== $xoops_config->xoops_root_path)
-		echo 'ERROR ';
-	else
-		echo 'OK ';	
-	echo "<br />\n";
-
-	echo 'XOOPS_TRUST_PATH:  ' ; 
-	if(XOOPS_TRUST_PATH !== $xoops_config->xoops_trust_path)
-		echo 'ERROR ';
-	else
-		echo 'OK ';	
-	echo "<br />\n";
-
-	echo 'XOOPS_URL:  ' ; 
-	if(XOOPS_URL !== $xoops_config->xoops_url)
-		echo 'ERROR ';
-	else
-		echo 'OK ';	
-	echo "<br />\n";
-
-	if (defined('XOOPS_SALT')){
-		echo 'XOOPS_SALT:  ' ; 
-		if(XOOPS_SALT !== $xoops_config->xoops_salt)
-			echo 'ERROR ';
-		else
-			echo 'OK ';	
-		echo "<br />\n";
-	}
-
-	if (defined('XOOPS_DB_SALT')){
-		echo 'XOOPS_DB_SALT:  ' ; 
-		if(XOOPS_DB_SALT !== $xoops_config->xoops_db_salt)
-			echo 'ERROR ';
-		else
-			echo 'OK ';	
-		echo "<br />\n";
-	}
-
-	echo 'XOOPS_DB_HOST:  ' ; 
-	if(XOOPS_DB_HOST !== $xoops_config->xoops_db_host)
-		echo 'ERROR ';
-	else
-		echo 'OK ';	
-	echo "<br />\n";
-
-	echo 'XOOPS_DB_USER:  ' ; 
-	if(XOOPS_DB_USER !== $xoops_config->xoops_db_user)
-		echo 'ERROR ';
-	else
-		echo 'OK ';	
-	echo "<br />\n";
-
-	echo 'XOOPS_DB_PASS:  ' ; 
-	if(XOOPS_DB_PASS !== $xoops_config->xoops_db_pass)
-		echo 'ERROR ';
-	else
-		echo 'OK ';	
-	echo "<br />\n";
-
-	echo 'XOOPS_DB_NAME:  ' ; 
-	if(XOOPS_DB_NAME !== $xoops_config->xoops_db_name)
-		echo 'ERROR ';
-	else
-		echo 'OK ';	
-	echo "<br />\n";
-
-	echo 'XOOPS_DB_PREFIX:  ' ; 
-	if(XOOPS_DB_PREFIX !== $xoops_config->xoops_db_prefix)
-		echo 'ERROR ';
-	else
-		echo 'OK ';	
-	echo "<br />\n";
-}
-
-function xpress_config_nomal_view()
-{
-	require_once dirname(dirname( __FILE__ )).'/class/config_from_xoops.class.php' ;
-	$xoops_config = new ConfigFromXoops;
-	
-	echo '<table width="400" cellspacing="1" cellpadding="1" border="1">';
-	echo '<tbody>';
-	echo '<tr>';
-	echo '<td>Define item</td>';
-	echo '<td>XOOPS setting value</td>';
-	echo '<td>xoops_config get value</td>';
-	echo '</tr>';
-	echo '<tr>';
-	if(XOOPS_ROOT_PATH !== $xoops_config->xoops_root_path)
-		echo '<td><strong><span style="color: rgb(255, 0, 0);">XOOPS_ROOT_PATH</span></strong></td>';
-	else
-		echo '<td>XOOPS_ROOT_PATH</td>';	
-	echo '<td>' . XOOPS_ROOT_PATH . '</td>';
-	echo '<td>' . $xoops_config->xoops_root_path . '</td>';
-	echo '</tr>';
-
-	echo '<tr>';
-	if(XOOPS_TRUST_PATH !== $xoops_config->xoops_trust_path)
-		echo '<td><strong><span style="color: rgb(255, 0, 0);">XOOPS_TRUST_PATH</span></strong></td>';
-	else
-		echo '<td>XOOPS_TRUST_PATH</td>';	
-	echo '<td>' . XOOPS_TRUST_PATH . '</td>';
-	echo '<td>' . $xoops_config->xoops_trust_path . '</td>';
-	echo '</tr>';
-
-	echo '<tr>';
-	if(XOOPS_URL !== $xoops_config->xoops_url)
-		echo '<td><strong><span style="color: rgb(255, 0, 0);">XOOPS_URL</span></strong></td>';
-	else
-		echo '<td>XOOPS_URL</td>';	
-	echo '<td>' . XOOPS_URL . '</td>';
-	echo '<td>' . $xoops_config->xoops_url . '</td>';
-	echo '</tr>';
-
-	if (defined('XOOPS_SALT')){
-		echo '<tr>';
-		if(XOOPS_SALT !== $xoops_config->xoops_salt)
-			echo '<td><strong><span style="color: rgb(255, 0, 0);">XOOPS_SALT</span></strong></td>';
-		else
-			echo '<td>XOOPS_SALT</td>';
-		echo '<td>' . XOOPS_SALT . '</td>';
-		echo '<td>' . $xoops_config->xoops_salt . '</td>';
-		echo '</tr>';
-	}
-
-	if (defined('XOOPS_DB_SALT')){
-		echo '<tr>';
-		if(XOOPS_DB_SALT !== $xoops_config->xoops_db_salt)
-			echo '<td><strong><span style="color: rgb(255, 0, 0);">XOOPS_DB_SALT</span></strong></td>';
-		else
-			echo '<td>XOOPS_DB_SALT</td>';
-		echo '<td>' . XOOPS_DB_SALT . '</td>';
-		echo '<td>' . $xoops_config->xoops_db_salt . '</td>';
-		echo '</tr>';
-	}
-
-	echo '<tr>';
-	if(XOOPS_DB_HOST !== $xoops_config->xoops_db_host)
-		echo '<td><strong><span style="color: rgb(255, 0, 0);">XOOPS_DB_HOST</span></strong></td>';
-	else
-		echo '<td>XOOPS_DB_HOST</td>';
-	echo '<td>' . XOOPS_DB_HOST . '</td>';
-	echo '<td>' . $xoops_config->xoops_db_host . '</td>';
-	echo '</tr>';
-
-	echo '<tr>';
-	if(XOOPS_DB_USER !== $xoops_config->xoops_db_user)
-		echo '<td><strong><span style="color: rgb(255, 0, 0);">XOOPS_DB_USER</span></strong></td>';
-	else
-		echo '<td>XOOPS_DB_USER</td>';
-	echo '<td>' . XOOPS_DB_USER . '</td>';
-	echo '<td>' . $xoops_config->xoops_db_user . '</td>';
-	echo '</tr>';
-
-	echo '<tr>';
-	if(XOOPS_DB_PASS !== $xoops_config->xoops_db_pass)
-		echo '<td><strong><span style="color: rgb(255, 0, 0);">XOOPS_DB_PASS</span></strong></td>';
-	else
-		echo '<td>XOOPS_DB_PASS</td>';
-	echo '<td>' . XOOPS_DB_PASS . '</td>';
-	echo '<td>' . $xoops_config->xoops_db_pass . '</td>';
-	echo '</tr>';
-
-	echo '<tr>';
-	if(XOOPS_DB_NAME !== $xoops_config->xoops_db_name)
-		echo '<td><strong><span style="color: rgb(255, 0, 0);">XOOPS_DB_NAME</span></strong></td>';
-	else
-		echo '<td>XOOPS_DB_NAME</td>';
-	echo '<td>' . XOOPS_DB_NAME . '</td>';
-	echo '<td>' . $xoops_config->xoops_db_name . '</td>';
-	echo '</tr>';
-
-	echo '<tr>';
-	if(XOOPS_DB_PREFIX !== $xoops_config->xoops_db_prefix)
-		echo '<td><strong><span style="color: rgb(255, 0, 0);">XOOPS_DB_PREFIX</span></strong></td>';
-	else
-		echo '<td>XOOPS_DB_PREFIX</td>';
-	echo '<td>' . XOOPS_DB_PREFIX . '</td>';
-	echo '<td>' . $xoops_config->xoops_db_prefix . '</td>';
-	echo '</tr>';
-	echo '</tbody>';
-	echo '</table>';
-}
-function xpress_config_from_xoops_view($is_report = false)
-{
-	global $xoopsUserIsAdmin,$xoopsUser;
-
-	$user_groups = $xoopsUser->getGroups();
-	$is_admin_group = in_array('1',$user_groups);
-	
-	require_once dirname(dirname( __FILE__ )).'/class/config_from_xoops.class.php' ;
-	$xoops_config = new ConfigFromXoops;
-	if ($is_report) {
-		echo "******** "  . _AM_XP2_XOOPS_CONFIG_INFO . "********" . "<br />\n";
-		xpress_config_report_view();
-		echo "<br />\n";
-	} else {
-		echo "<fieldset><legend style='font-weight: bold; color: #900;'>" . _AM_XP2_XOOPS_CONFIG_INFO . "</legend>";
-		echo "<div style='padding: 8px;'>";
-		if ($xoopsUserIsAdmin && $is_admin_group){
-			xpress_config_nomal_view();
-		} else {
-			xpress_config_report_view();
-		}
-		echo "</div>";
-		echo '</legend>';
-		echo "</fieldset><br />";
-	}
-}
 
 function xpress_state($is_report = false)
@@ -818,5 +605,4 @@
 	if (!empty($_POST['submit_report'])) $report = true; else $report = false;
 	xpress_sys_info($report);
-	xpress_config_from_xoops_view($report);
 	xpress_active_plugin_list($report);
 	xpress_block_state($report);
Index: branches/Ver3.0/xpressme_integration_kit/class/config_from_xoops.class.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/class/config_from_xoops.class.php	(revision 756)
+++ 	(revision )
@@ -1,162 +1,0 @@
-<?php
-/*
- * XPressME - WordPress for XOOPS
- *
- * @copyright	XPressME Project http://www.toemon.com
- * @license		http://www.fsf.org/copyleft/gpl.html GNU public license
- * @author		toemon
- * @package		module::xpress
- */
-
-/* 
- * The function to acquire only a set value without calling the XOOPS system is here.
- */
-require_once dirname( __FILE__ ).'/wpInfo_class.php' ;
-
-class ConfigFromXoops{
-	var $xoops_mainfile_path;
-	var $define_arry = array();	
-	var $external_define_path;
-	var $xp_config_file_path;
-	var $xoops_root_path;
-	var $xoops_url;
-	var $xoops_trust_path;
-	var $xoops_cache_path;
-	var $xoops_db_prefix;
-	var $xoops_db_name;
-	var $xoops_db_user;
-	var $xoops_db_pass;
-	var $xoops_db_host;
-	var $module_name;
-	var $module_path;
-	var $module_url;
-	var $module_db_prefix;
-	var $module_version;
-	var $module_codename;	
-	var $xoops_upload_path;
-	var $xoops_upload_url;
-	var $xoops_db_salt;
-	var $xoops_salt;
-	var $is_impress;
-	var $impress_db_config_file;
-	var $wp_db_version;
-	var $wp_version;
-	var $is_wp_me;
-	var $xoops_language;
-	var $module_id;
-	var $module_config= array();
-	var $xoops_time_zone;
-	var $xoops_var_path;
-	var $xoops_db_charset;
-	var $xoops_db_pconnect;
-	var $xoops_path;
-	var $xoops_lang;
-	var $wp_lang;
-	
-	function __constructor()	//for PHP5
-    {
-        $this->ConfigFromXoops();
-       
-    }
-    
-    function ConfigFromXoops()	//for PHP4 constructor
-    {  
-    	$this->xoops_mainfile_path = $this->get_xoops_mainfile_path();
-    	$this->module_path=dirname(dirname(__FILE__));
-    	$this->module_name=basename($this->module_path);
-    	$this->xp_config_file_path = $this->module_path . '/xp-config.php';
-    	
-    	// start /admin/index.php page detect
-    	$php_script_name = $_SERVER['SCRIPT_NAME'];
-		$php_query_string = $_SERVER['QUERY_STRING'];
-		$admin_page = 	basename(dirname(dirname(__FILE__))) . '/admin/index.php';
-		$is_xoops_module_admin = false;
-		if (strstr($php_script_name,$admin_page) !== false) $is_xoops_module_admin = true;
-		if (strstr($php_query_string,$admin_page) !== false) $is_xoops_module_admin = true;
-    	$this->_get_value_by_xoops_define();
-		//  define from /settings/definition.inc.php (XCL)  or /include/common.php(2016a-JP)
-		$this->xoops_upload_path = $this->xoops_root_path .'/uploads';
-		$this->xoops_upload_url = $this->xoops_url . '/uploads';
-		$this->module_db_prefix = $this->xoops_db_prefix  . '_' . preg_replace('/wordpress/','wp',$this->module_name) . '_';
-		
-		$this->set_module_version();
-		$this->set_wp_version();
-		if (function_exists('date_default_timezone_get')){
-			$this->xoops_time_zone = date_default_timezone_get();
-		}
-		$this->_get_cache_path();
-    }
-
-	// A set value is acquired from XOOPS define value .
-	function _get_value_by_xoops_define(){
-		$this->xoops_root_path = XOOPS_ROOT_PATH;
-		$this->xoops_url = XOOPS_URL;
-		$this->module_url = $this->xoops_url . '/modules/' . $this->module_name;
-		if(defined('XOOPS_TRUST_PATH')) $this->xoops_trust_path = XOOPS_TRUST_PATH; else $this->xoops_trust_path = '';
-		$this->xoops_db_prefix = XOOPS_DB_PREFIX;
-		$this->xoops_db_name = XOOPS_DB_NAME;
-		$this->xoops_db_user = XOOPS_DB_USER;
-		$this->xoops_db_pass = XOOPS_DB_PASS;
-		$this->xoops_db_host = XOOPS_DB_HOST;
-		if(defined('XOOPS_DB_SALT')) $this->xoops_db_salt = XOOPS_DB_SALT; else $this->xoops_db_salt = '';
-		if(defined('XOOPS_SALT')) $this->xoops_salt = XOOPS_SALT; else $this->xoops_salt = '';
-		$this->xoops_lang =  @$GLOBALS["xoopsConfig"]['language'];
-		$wp_info = new wpInfo;
-		$this->wp_lang = $wp_info->get_wpLang($this->xoops_lang);
-
-	}
-	
-	// call after the $this->xoops_trust_path is set
-	function _get_cache_path(){
-		$cache_path = $this->xoops_trust_path . '/cache';
-		if (file_exists($cache_path) && is_writable($cache_path)){
-			$this->xoops_cache_path = $cache_path;
-			return;
-		}
-		$this->xoops_cache_path = $this->xoops_root_path . '/cache';
-	}
-    
-    function get_xoops_mainfile_path(){
-    	return dirname(dirname(dirname(dirname(__FILE__)))) . '/mainfile.php';
-    }
-    
-    // set XPressME module virsion and codename from xoops_versions.php
-    function set_module_version(){
-    	$xoops_version_file = dirname(dirname(__FILE__)) . '/xoops_version.php';
-		if(file_exists($xoops_version_file)){
-			$version_file = file($xoops_version_file);
-			$version_pattern = '^\s*(\$modversion\[\s*\'version\'\s*\])\s*=\s*[\'"]([^\'"]*)[\'"]';
-			$codename_pattern = '^\s*(\$modversion\[\s*\'codename\'\s*\])\s*=\s*[\'"]([^\'"]*)[\'"]';
-			$version_found = false;
-			$codename_found = false;
-			for ($i = 0 ; $i <count($version_file) ; $i++){
-				if (preg_match( "/$version_pattern/", $version_file[$i] ,$v_matches )){
-					$this->module_version = $v_matches[2];
-					$version_found = true;
-				}
-				if (preg_match( "/$codename_pattern/", $version_file[$i] ,$c_matches )){
-					$this->module_codename = $c_matches[2];
-					$codename_found = true;
-				}
-				if ( $version_found && $codename_found ) break;
-			}
-		}
-    }
-    
-    function set_wp_version(){
-    	include dirname(dirname(__FILE__)) . '/wp-includes/version.php';
-    	
-    	$this->wp_db_version = $wp_db_version;
-		
-		$this->wp_version = str_replace("ME", "", $wp_version);
-		
-		$pattern = 'ME.*';
-    	if (preg_match('/' . $pattern . '/' ,$wp_version)){
-			$this->is_wp_me = true;
-		} else {
-			$this->is_wp_me = true;
-		}
-    }
-    
-}
-?>
Index: branches/Ver3.0/xpressme_integration_kit/class/modInfo_class.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/class/modInfo_class.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/class/modInfo_class.php	(revision 757)
@@ -9,9 +9,7 @@
  */
 
-/* 
- * The function to acquire only a set value without calling the XOOPS system is here.
- */
-
-class modInfo{
+if (defined( 'XOOPS_MAINFILE_INCLUDED')) :
+
+class modInfoClass {
 	var $xoops_mainfile_path;
 	var $xoops_root_path;
@@ -27,8 +25,4 @@
 	var $xoops_language;
 	var $module_db_prefix;
-	var $db_name;
-	var $db_user;
-	var $db_pass;
-	var $db_host;
 	var $module_name;
 	var $module_path;
@@ -37,53 +31,100 @@
 	var $module_codename;
 	var $module_id;
-	var $is_impress;
+	var $xoops_version;
+	var $is_impress_cms;
+	var $is_cube_legacy;
+	var $is_xoops2jp;
+	var $is_xoops2;
+	var $is_xoops_legacy;
+	var $is_jpex;
 	var $xoops_time_zone;
+	var $wp_version;
+	var $wpConfigInfo;
 	
 	function __constructor()	//for PHP5
     {
-        $this->xpressInfo();
+        $this->modInfoClass();
        
     }
     
-    function modInfo()	//for PHP4 constructor
+    function modInfoClass()	//for PHP4 constructor
     {  
-    	global $xoopsModule;
-    	
-    	$this->xoops_mainfile_path = dirname(dirname(dirname(dirname(__FILE__)))) . '/mainfile.php';
-    	$this->module_path=dirname(dirname(__FILE__));
-    	$this->module_name=basename($this->module_path);
+    	global $xoopsModule,$wpConfigInfo;
+    	if (is_object($wpConfigInfo)){
+    		include_once dirname(__FILE__).'/wpConfigInfo_class.php';
+    		$this->wpConfigInfo = new wpConfigInfoClass;
+    	}
 		$this->xoops_root_path = XOOPS_ROOT_PATH;
 		$this->xoops_trust_path = (defined('XOOPS_TRUST_PATH')) ? XOOPS_TRUST_PATH : '';
 		$this->xoops_url = XOOPS_URL;
-		$this->module_url = $this->xoops_url . '/modules/' . $this->module_name;
+    	$this->xoops_mainfile_path = XOOPS_ROOT_PATH . '/mainfile.php';
 		$this->xoops_upload_path = XOOPS_UPLOAD_PATH;
 		$this->xoops_upload_url = XOOPS_UPLOAD_URL;
 		$this->xoops_cache_path = XOOPS_CACHE_PATH;
-		$this->db_prefix = XOOPS_DB_PREFIX;
-		$this->module_db_prefix = $this->xoops_db_prefix  . '_' . preg_replace('/wordpress/','wp',$this->module_name) . '_';
-		$this->db_name = XOOPS_DB_NAME;
-		$this->db_user = XOOPS_DB_USER;
-		$this->db_pass = XOOPS_DB_PASS;
-		$this->db_host = XOOPS_DB_HOST;
-		$this->xoops_db_salt = (defined('XOOPS_DB_SALT')) ? XOOPS_DB_SALT : '';
-		$this->xoops_salt = (defined('XOOPS_SALT')) ? XOOPS_SALT : '';
+    	$this->module_path=dirname(dirname(__FILE__));
+    	$this->module_name=basename($this->module_path);
+		$this->module_url = $this->xoops_url . '/modules/' . $this->module_name;
+		$this->xoops_db_prefix = XOOPS_DB_PREFIX . '_';
+		$this->module_db_prefix = $this->_get_module_db_prefix();
 		$this->xoops_lang =  @$GLOBALS["xoopsConfig"]['language'];
 		$this->module_id =! empty($xoopsModule) ? $xoopsModule->getVar('mid') : 0;
 		$this->module_version = empty($xoopsModule) ? $xoopsModule->getVar('version') : '';
-		$module_codename = $this->_get_module_codename();
-    	// start /admin/index.php page detect
-    	$php_script_name = $_SERVER['SCRIPT_NAME'];
-		$php_query_string = $_SERVER['QUERY_STRING'];
-		$admin_page = 	basename(dirname(dirname(__FILE__))) . '/admin/index.php';
-		$is_xoops_module_admin = false;
-		if (strstr($php_script_name,$admin_page) !== false) $is_xoops_module_admin = true;
-		if (strstr($php_query_string,$admin_page) !== false) $is_xoops_module_admin = true;
+		$this->module_codename = $this->_get_module_codename();
+		$this->wp_version = $this->_get_wp_version();
+		
+		$this->xoops_version = (defined('XOOPS_VERSION')) ? XOOPS_VERSION : '';
+    	$this->_branches_cores();
 		
 		if (function_exists('date_default_timezone_get')){
 			$this->xoops_time_zone = date_default_timezone_get();
 		}
+
     }
 
-    
+	function _get_module_db_prefix(){
+    	$module_db_prefix = XOOPS_DB_PREFIX . '_' . preg_replace('/wordpress/','wp',$this->module_name);
+    	return $module_db_prefix;
+	}
+    function _branches_cores(){
+    	/*  XOOPS include/version.php define value */
+		//define("XOOPS_VERSION","XOOPS 2.0.16a JP");
+		//define("XOOPS_VERSION", "XOOPS Cube Legacy 2.2");
+		//define('XOOPS_VERSION', 'ImpressCMS 1.1.2 Final');
+		//define("XOOPS_VERSION", "XOOPS JPEx 1.6");
+		//define("XOOPS_VERSION", "XOOPS 2.3.3");
+		//define("XOOPS_VERSION", "Xoops Legacy");	define("XOOPS_ENGINE", "legacy");
+    	$this->is_impress_cms = false;
+		$this->is_cube_legacy = false;
+		$this->is_xoops2jp = false;
+		$this->is_xoops2 = false;
+		$this->is_xoops_legacy = false;
+		$this->is_jpex = false;
+		
+		$version = XOOPS_VERSION;
+		
+		
+    	// branches by cores
+		if( preg_match('/JP$/', $this->xoops_version))
+			$this->is_xoops2jp = true;
+		if( preg_match('/Cube\s*Legacy/', $this->xoops_version))
+			$this->is_cube_legacy = true;
+		if( preg_match('/ImpressCMS/', $this->xoops_version))
+			$this->is_impress_cms = true;
+		if( preg_match('/JPEx/', $this->xoops_version))
+			$this->is_jpex = true;
+		if( preg_match('/XOOPS\s*[0-9|\.]*$/', $this->xoops_version))
+			$this->is_xoops2 = true;
+		if( preg_match('/Xoops\s*Legacy/', $this->xoops_version))
+			$this->is_xoops_legacy = true;
+	}
+    function _get_wp_version(){
+    	$wp_version_file =  dirname(dirname(__FILE__)) . '/wp-includes/version.php';
+    	if (file_exists($wp_version_file)){
+    		include $wp_version_file;
+    		return str_replace("ME", "", $wp_version);
+    	}
+    	return '';
+    }
+	
     // get XPressME module virsion and codename from xoops_versions.php
     function _get_module_codename(){
@@ -100,5 +141,116 @@
 		return '';
     }
-    
+	function get_xoops_db_prefix(){
+		return $this->xoops_db_prefix;
+	}
+	
+	function get_xoops_root_path(){
+		return $this->xoops_root_path;
+	}
+	function get_xoops_trust_path(){
+		return $this->xoops_trust_path;
+	}
+	function get_xoops_mainfile_path(){
+		return $this->xoops_mainfile_path;
+	}
+	function get_xoops_header_path(){
+		return $this->xoops_root_path ."/header.php";
+	}
+	function get_xoops_footer_path(){
+		return $this->xoops_root_path . '/footer.php';
+	}
+	function get_xoops_cache_path(){
+		return $this->xoops_cache_path;
+	}
+	function get_xoops_url(){
+		return $this->xoops_url;
+	}
+	function get_xoops_upload_path(){
+		return $this->xoops_upload_path;
+	}
+	function get_xoops_upload_url(){
+		return $this->xoops_upload_url;
+	}
+	function get_module_path(){
+		return $this->module_path;
+	}
+	function get_module_templates_path(){
+		return $this->module_path . '/templates';
+	}
+	
+	function get_module_name(){
+		return $this->module_name;
+	}
+	function get_module_dirname(){
+		return $this->module_name;
+	}
+	function get_module_url(){
+		return $this->module_url;
+	}
+ 	function get_module_db_prefix(){
+		return $this->xpress_db_prefix;
+	}
+ 	function get_xoops_time_zone(){
+		return $this->xoops_time_zone;
+	}
+ 	function get_module_version(){
+		return $this->module_version;
+	}
+ 	function get_module_codename(){
+		return $this->module_codename;
+	}
+ 	function get_wp_version(){
+		return $this->wp_version;
+	}
+ 	function get_module_full_version(){
+		return $this->module_version . $this->module_codename;
+	}
+	
+ 	function is_impress_cms(){
+		return $this->is_impress_cms;
+	}
+ 	function is_cube_legacy(){
+		return $this->is_cube_legacy;
+	}
+ 	function is_xoops2jp(){
+		return $this->is_xoops2jp;
+	}
+ 	function is_xoops2(){
+		return $this->is_xoops2;
+	}
+ 	function is_xoops_legacy(){
+		return $this->is_xoops_legacy;
+	}
+ 	function is_jpex(){
+		return $this->is_jpex;
+	}
+	
+	function get_moduleID_ByDirname($dir_name){
+		$module_handler =& xoops_gethandler('module');
+		$module =& $module_handler->getByDirname($dir_name);
+		$module_id = $module->getVar('mid');
+	}
+	
+	function get_moduleID(){
+		global $xoopsModule;
+		$module_id = $xoopsModule->getVar('mid');
+		return $module_id;
+	}
+	
+	function get_ModuleConfig($key_name=''){
+		if (empty($key_name)) return '';
+		global $xoopsModuleConfig;
+		$value = isset($xoopsModuleConfig[$key_name]) ? $xoopsModuleConfig[$key_name] : '';
+	}
+	
+	function get_ModuleConfig_ByDirname($dir_name,$key_name=''){
+		$mid = $this->get_moduleID_ByDirname($dir_name);
+		$conf_handler =& xoops_gethandler('config');
+		$modConfig = $conf_handler->getConfigsByCat(0, $mid);
+		if(empty($modConfig)) return '';
+		if(empty($key_name)) return $modConfig;
+		return isset($modConfig[$key_name]) ? $modConfig[$key_name] : '';
+	}
+   
    	function is_wpdb_installed(){
    		global $xoopsDB;
@@ -111,5 +263,12 @@
 		return false;
 	}
-	
+	function is_wp_file_found()
+	{
+		if (!file_exists($this->module_path . '/wp-settings.php')){
+			return false;
+		}
+		return true;
+	}
+
 	function is_writeable_mode($check_file) {
         if (!is_dir($check_file)) {
@@ -135,5 +294,32 @@
     	return true;
 	}
+	function get_php_version()
+	{
+		if (function_exists('phpversion'))
+			return phpversion();
+		else 
+			return '';
+	}
+	function get_mysql_version()
+	{
+		global $xoopsDB;
+		list($SV) = $xoopsDB->fetchRow($xoopsDB->query('SELECT version()'));
+		return $SV;
+	}
+	public function get_mod_image_link($file_name='') 
+	{
+		$link_url = '';
+		if(!empty($file_name)){
+			if(file_exists($this->module_path.'/images/'.$file_name)){
+				$link_url = '<img alt="'.$file_name.'" src="'. $this->mod_url .'/images/'.$file_name.'" title="'.$file_name.'" align=top>';
+			}
+		}
+		return $link_url;
+	}
+	function get_wpLang($xoops_lang=''){
+		return $this->wpConfigInfo->get_wpLang($xoops_lang);
+	}
 	
 }
+endif;
 ?>
Index: branches/Ver3.0/xpressme_integration_kit/class/wpConfigInfo_class.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/class/wpConfigInfo_class.php	(revision 757)
+++ branches/Ver3.0/xpressme_integration_kit/class/wpConfigInfo_class.php	(revision 757)
@@ -0,0 +1,98 @@
+<?php
+/*
+ * XPressME - WordPress for XOOPS
+ *
+ * @copyright	XPressME Project http://www.toemon.com
+ * @license		http://www.fsf.org/copyleft/gpl.html GNU public license
+ * @author		toemon
+ * @package		module::xpress
+ */
+
+if (defined( 'XOOPS_MAINFILE_INCLUDED')) :
+require_once dirname( __FILE__ ).'/langInfo_class.php' ;
+
+class wpConfigInfoClass {
+	var $xoops_db_prefix;
+	var $db_prefix;
+	var $db_name;
+	var $db_user;
+	var $db_pass;
+	var $db_host;
+	var $db_salt;
+	var $langInfo;
+	
+	function __constructor()	//for PHP5
+    {
+        $this->wpConfigInfoClass();
+    }
+    
+    function wpConfigInfoClass()	//for PHP4 constructor
+    {
+		global $xoopsModule;
+		$this->xoops_db_prefix = XOOPS_DB_PREFIX .'_';
+		$this->db_prefix = $this->_get_wp_db_prefix();
+		$this->db_name = XOOPS_DB_NAME;
+		$this->db_user = XOOPS_DB_USER;
+		$this->db_pass = XOOPS_DB_PASS;
+		$this->db_host = XOOPS_DB_HOST;
+		if(!defined('XOOPS_DB_NAME') ) $this->_get_resource_db_ini();
+		$this->db_salt = (defined('XOOPS_DB_SALT')) ? XOOPS_DB_SALT : '';
+		require_once dirname( __FILE__ ).'/langInfo_class.php' ;
+		$this->langInfo = new langInfoClass;
+    }
+	function _get_wp_db_prefix(){
+		$module_name = basename(dirname(dirname(__FILE__)));
+    	$module_db_prefix = XOOPS_DB_PREFIX . '_' . preg_replace('/wordpress/','wp',$module_name) . '_';
+    	return $module_db_prefix;
+	}
+
+	// XOOPS3 doesn't define the DB connection information in the constant.
+    function _get_resource_db_ini(){
+		if(!defined('XOOPS_VAR_PATH') ) return;
+		$def_file = XOOPS_VAR_PATH . '/etc/resource.db.ini.php';
+		if(! file_exists($def_file)) return;
+		$array_file = file($def_file);
+		foreach ($array_file as $line){
+			if (preg_match('/^\s*dbname\s*=\s*[\'"](.*)[\'"]/' ,$line,$matchs))
+				$this->db_name = $matchs[1];
+			if (preg_match('/^\s*host\s*=\s*[\'"](.*)[\'"]/' ,$line,$matchs))
+				$this->db_host = $matchs[1];
+			if (preg_match('/^\s*username\s*=\s*[\'"](.*)[\'"]/' ,$line,$matchs))
+				$this->db_user = $matchs[1];
+			if (preg_match('/^\s*password\s*=\s*[\'"](.*)[\'"]/' ,$line,$matchs))
+				$this->db_pass = $matchs[1];
+			if (preg_match('/^\s*prefix\s*=\s*[\'"](.*)[\'"]/' ,$line,$matchs))
+				$this->db_prefix = $matchs[1];
+		}
+	}
+	
+	function get_xoops_db_prefix(){
+		return $this->xoops_db_prefix;
+	}
+	function get_db_prefix(){
+		return $this->db_prefix;
+	}
+	function get_wp_db_prefix(){
+		return $this->db_prefix;
+	}
+	function get_db_name(){
+		return $this->db_name;
+	}
+	function get_db_user(){
+		return $this->db_user;
+	}
+	function get_db_pass(){
+		return $this->db_pass;
+	}
+	function get_db_host(){
+		return $this->db_host;
+	}
+	function get_db_salt(){
+		return $this->db_salt;
+	}
+	function get_wpLang($xoops_lang=''){
+		return $this->langInfo->get_wpLang($xoops_lang);
+	}
+}
+endif;
+?>
Index: branches/Ver3.0/xpressme_integration_kit/class/wpInfo_class.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/class/wpInfo_class.php	(revision 756)
+++ 	(revision )
@@ -1,228 +1,0 @@
-<?php
-/*
- * XPressME - WordPress for XOOPS
- *
- * @copyright	XPressME Project http://www.toemon.com
- * @license		http://www.fsf.org/copyleft/gpl.html GNU public license
- * @author		toemon
- * @package		module::xpress
- */
-class wpInfo {
-	var	$mod_dirpath;
-	var	$mod_name;
-	var $mod_url;
-
-	var $xoops_Lang;
-	var $wp_Lang;
-	var $php_version;
-	var $mysql_version;
-	// The language of XOOPS is set as Key of the array. 
-	// The language of WP is set as Value of the array. 
-	var $wp_lang_array = array(
-		'english' => 	'en_US',
-		'japanese' => 	'ja',
-		'ja_utf8' => 	'ja',
-		'pt-br_utf8' =>	'pt_BR',
-		// The key(language of XOOPS) of the following lists has not been set yet. 
-		'Afrikaans' =>	'af',
-		'Albanian' =>	'al',
-		'Arabic' =>		'ar',
-		'Bangla' =>		'bn_BD',
-		'Basque' =>		'eu',
-		'Belarusian' =>	'be_BY',
-		'Bosnian' =>	'bs_BA',
-		'Bulgarian' =>	'bg_BG',
-		'Catalan' =>	'ca',
-		'Chinese' =>	'zh_CN',
-		'Hong Kong' =>	'zh_HK',
-		'Taiwan' =>		'zh_TW',
-		'Croatian' =>	'hr',
-		'Czech' =>		'cs_CZ',
-		'Danish' =>		'da_DK',
-		'Dutch' =>		'nl_NL',
-		'Esperanto' =>	'eo',
-		'Estonian' =>	'et',
-		'Faroese' =>	'fo',
-		'Finnish' =>	'fi',
-		'Galician' =>	'gl_ES',
-		'Georgian' =>	'ge_GE',
-		'German' =>		'de_DE',
-		'Greek' =>		'el',
-		'Hebrew' =>		'he_IL',
-		'Hungarian' =>	'hu_HU',
-		'Icelandic' =>	'is_IS',
-		'Indonesian' =>	'id_ID',
-		'Italian' =>	'it_IT',
-		'Khmer' =>		'km_KH',
-		'ko_utf8' =>	'ko_KR',
-		'Latvian' =>	'lv',
-		'Lithuanian' =>	'lt_LT',
-		'Macedonian' =>	'mk_MK',
-		'Malagasy' =>	'mg_MG',
-		'Malay' =>		'ms_MY',
-		'Nias' =>		'ni_ID',
-		'Norwegian' =>	'nb_NO',
-		'Persian' =>	'fa_IR',
-		'Polish' =>		'pl_PL',
-		'European Portuguese' =>	'pt_PT',
-		'Romanian' =>	'ro',
-		'Russian' =>	'ru_RU',
-		'Serbian' =>	'sr_RS',
-		'Sinhala' =>	'si_LK',
-		'Slovak' =>		'sk_SK',
-		'Slovenian' =>	'sl_SI',
-		'Spanish' =>	'es_ES',
-		'Sundanese' =>	'su_ID',
-		'Swedish' =>	'sv_SE',
-		'Tajik' =>		'tg',
-		'Thai' =>		'th',
-		'Turkish' =>	'tr',
-		'Ukrainian' =>	'uk',
-		'Uzbek' =>		'uz_UZ',
-		'Vietnamse' =>	'vi',
-		'Welsh' =>		'cy',
-	);
-
-	function wpInfo(){
-		$this->__construct();
-	}
-	function __construct() {
-		global $xoopsDB;
-		$this->mod_dirpath = dirname(dirname(__FILE__));
-		$this->mod_name = basename(dirname(dirname(__FILE__)));
-		$this->mod_url = XOOPS_URL . '/modules/'.$this->mod_name;
-		$this->load_lang();
-		$this->xoops_Lang = @$GLOBALS["xoopsConfig"]['language'];
-		$this->php_version    = phpversion();
-		list($SV) = $xoopsDB->fetchRow($xoopsDB->query('SELECT version()'));
-		$this->mysql_version = $SV;
-
-		$this->get_wpLang();
-	}
-	function text_indent($text,$num = 1,$css_option='')
-	{
-		$ret = '';
-		$px = 24 * $num;
-		$ret = '<div style="padding-left:' .$px .'px;'.$css_option.'">';
-		$ret .= $text . '</div>';
-		return $ret;
-	}
-	public function load_lang()
-	{
-		$lang = @$GLOBALS["xoopsConfig"]['language'];
-
-		// language file (modinfo.php)
-		if( file_exists( $this->mod_dirpath .'/language/'.$lang.'/admin.php' ) ) {
-			include_once $this->mod_dirpath .'/language/'.$lang.'/admin.php' ;
-		} else if( file_exists(  $this->mod_dirpath .'/language/english/admin.php' ) ) {
-			include_once $this->mod_dirpath .'/language/english/admin.php' ;
-		}
-	}
-	
-	public function get_php_version()
-	{
-		return $this->php_version;
-	}
-	public function get_mysql_version()
-	{
-		return $this->mysql_version;
-	}
-	public function get_wpLang($xoops_Lang = '') 
-	{
-		if(!empty($xoops_Lang)) $this->xoops_Lang = $xoops_Lang;
-		$this->wp_Lang = $this->wp_lang_array[$this->xoops_Lang];
-		if (empty($this->wp_Lang)) $this->wp_Lang =  'en_US';
-		return $this->wp_Lang;
-	}
-	public function get_mod_image_link($file_name='') 
-	{
-		$link_url = '';
-		if(!empty($file_name)){
-			if(file_exists($this->mod_dirpath.'/images/'.$file_name)){
-				$link_url = '<img alt="'.$file_name.'" src="'. $this->mod_url .'/images/'.$file_name.'" title="'.$file_name.'" align=top>';
-			}
-		}
-		return $link_url;
-	}
-
-	function is_wpdb_installed(){
-		global $xoopsDB;
-		$prefix_mod = XOOPS_DB_PREFIX .'_' . preg_replace('/wordpress/','wp',$this->mod_name) . '_';
-		$sql = "SHOW TABLES LIKE '$prefix_mod%'";
-		if ($result = $xoopsDB->queryf($sql)){
-			if($xoopsDB->getRowsNum($result))  return true;
-		}
-		return false;
-	}
-	
-	public function is_wp_file_found()
-	{
-		if (!file_exists($this->mod_dirpath . '/wp-settings.php')){
-			return false;
-		}
-		return true;
-	}
-	public function get_download_info($locale='')
-	{
-		$local_package = '';
-		$mysql_version = preg_replace('/[^0-9.].*/', '', $this->mysql_version);
-		$php_version = $this->php_version;
-
-		if (empty($locale)) $locale = $this->wp_Lang;
-
-/* test		
-		$mysql_version='4.0.27';
-		$php_version = '4.1.1';
-*/
-		// wprdpress original option
-		// ?version=$wp_version&php=$php_version&locale=$locale&mysql=$mysql_version&local_package=$local_package";
-		$option = "?php=$php_version&locale=$locale&mysql=$mysql_version&local_package=$local_package";
-		$url = "http://api.wordpress.org/core/version-check/1.5/" .$option;
-		$handle = @fopen($url,'r');
-		if ($handle) {
-			$ans = array();
-			$num = 0;
-			$pos = 0;
-	    	while (($buffer = fgets($handle, 4096)) !== false) {
-	    		$buffer = trim($buffer);
-	    		if (strlen($buffer) == 0) {
-	    			$num++;
-	    			$pos=0;
-	    		} else {
-	    			$ans[$num][$pos] = $buffer;
-	    			$pos++;
-	    		}
-	    	}
-	    	if (!feof($handle)) {
-	        	echo "Error: unexpected fgets() fail\n";
-	    	}
-	    	fclose($handle);
-		}
-			$ressponce = $ans[0][0];
-			$site_url = $ans[0][1];
-			$download_url = $ans[0][2];
-			$wp_version = $ans[0][3];
-			$download_lang = $ans[0][4];
-//			print_r($ans);
-			if (isset($ans[1])){
-				$en_download_url = $ans[1][2];
-			}
-			$ret = $this->text_indent('(Check URL: '.$url.')',3);
-			if ($locale == $download_lang){
-				$ret .= $this->text_indent(sprintf(_AM_XP2_WP_INFO_1,$locale),2);
-				$ret .= $this->text_indent('<a href="'.$download_url.'">' . $download_url .'</a>' ,3);
-				if (!empty($en_download_url)){
-					$ret .= $this->text_indent(_AM_XP2_WP_INFO_4,2);
-					$ret .= $this->text_indent('<a href="'.$en_download_url .'">' . $en_download_url .'</a>' ,3);
-				}
-			} else {
-				$ret .= $this->text_indent(sprintf(_AM_XP2_WP_INFO_2,$locale));
-				$ret .= $this->text_indent(_AM_XP2_WP_INFO_3,2);
-				$ret .= $this->text_indent('<a href="http://codex.wordpress.org/WordPress_in_Your_Language" target="	_blank">WordPress_in_Your_Language</a>' ,3);
-				$ret .= $this->text_indent(_AM_XP2_WP_INFO_4,2);
-				$ret .= $this->text_indent('<a href="'.$download_url.'">' . $download_url .'</a>' ,3);
-			}
-			echo $ret;
-		}
-	}
-?>
Index: branches/Ver3.0/xpressme_integration_kit/class/xpressD3commentContent.class.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/class/xpressD3commentContent.class.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/class/xpressD3commentContent.class.php	(revision 757)
@@ -44,7 +44,7 @@
 		function displayCommentsInline( $params )
 		{
-			global $xoops_config;
+			global $modInfo;
 			if ( function_exists('date_default_timezone_set') )
-				date_default_timezone_set($xoops_config->xoops_time_zone);
+				date_default_timezone_set($modInfo->get_xoops_time_zone());
 			$new_params = $this->restructParams( $params ) ;
 			if (!$this->canAddComment($params['id']) ) {
Index: branches/Ver3.0/xpressme_integration_kit/include/add_xpress_config.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/include/add_xpress_config.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/include/add_xpress_config.php	(revision 757)
@@ -20,15 +20,12 @@
 
 require_once dirname(dirname(dirname(dirname( __FILE__ )))).'/mainfile.php' ;
-require_once dirname( __FILE__ ).'/xoops3_define.php' ;
-get_xoops3_define();
 
 $_SERVER['REQUEST_METHOD'] = $request_method; //It returns it to former data. 
 
 require_once dirname( __FILE__ ).'/xpress_debug_log.php' ;
-require_once dirname(dirname( __FILE__ )).'/class/config_from_xoops.class.php' ;
-$xoops_config = new ConfigFromXoops;
-// TEST modInfo_class
+require_once dirname(dirname( __FILE__ )).'/class/wpConfigInfo_class.php' ;
+$wpConfigInfo = new wpConfigInfoClass;
 require_once dirname(dirname( __FILE__ )).'/class/modInfo_class.php' ;
-$mod_info = new modInfo;
+$modInfo = new modInfoClass;
 require_once dirname( __FILE__ ).'/set_cash_cookie_path.php' ;
 ?>
Index: branches/Ver3.0/xpressme_integration_kit/include/add_xpress_process.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/include/add_xpress_process.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/include/add_xpress_process.php	(revision 757)
@@ -14,5 +14,5 @@
 }
 function safe_site_url(){
-	global $xoops_config,$blog_id,$blogname;
+	global $modInfo,$blog_id,$blogname;
 	
 	if (is_xpress_index_page_call()){
@@ -35,6 +35,6 @@
 		$siteurl = get_option('siteurl');
 		$home = get_option('home');
-		$module_url = $xoops_config->module_url;
-		$module_name = $xoops_config->module_name;
+		$module_url = $modInfo->get_module_url();
+		$module_name = $modInfo->get_module_name();
 		$schema = ( isset($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) == 'on' ) ? 'https://' : 'http://';
 		$guess_url = preg_replace('|/' . $module_name . '/.*|i', '/' . $module_name, $schema . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'] );
@@ -59,5 +59,5 @@
 		}
 		if ($site_url_error || $home_url_error){
-			include $xoops_config->xoops_root_path ."/header.php";
+			include $modInfo->get_xoops_header_path();
 			$form = '<form method="post" action="' . $_SERVER["REQUEST_URI"] . '">'."\n";
 			$form .= '<table cellspacing="1" cellpadding="1" border="0">';
@@ -94,5 +94,5 @@
 			$form .= '</form>' ."\n";
 			echo $form;
-			include $xoops_config->xoops_root_path . '/footer.php';
+			include $modInfo->get_xoops_footer_path();
 			exit();
 		}
@@ -103,7 +103,7 @@
 			$form .= '<input type="submit" value= "'.__('Permalink Settings').'" name="submit_redirect" />' ."\n";
 			$form .= '</form>' ."\n";
-			include $xoops_config->xoops_root_path ."/header.php";
+			include $modInfo->get_xoops_header_path();
 			echo $form;
-			include $xoops_config->xoops_root_path . '/footer.php';
+			include $modInfo->get_xoops_footer_path();
 			exit();
 		}
@@ -118,19 +118,10 @@
 	require_once( dirname( __FILE__ ).'/wp_check.php');
 	if (!is_wpdb_installed()){
-		include $xoops_config->xoops_root_path ."/header.php";
+		include $modInfo->get_xoops_header_path();
 		echo "<h2>Wordpress has not been installed yet. </h2>";
-		include $xoops_config->xoops_root_path . '/footer.php';
+		include $modInfo->get_xoops_footer_path();
 		exit();
 	}
 
-	//$_SERVER['REQUEST_METHOD'] = 'POST' is
-	//When notifying by a private message, Notification_reserve_send();
-	//it is evaded that the data base becomes read-only as a result of the check on the referrer and the method. 
-/*
-	$request_method =  (isset($_SERVER['REQUEST_METHOD'])) ? $_SERVER['REQUEST_METHOD'] : '';
-	$_SERVER['REQUEST_METHOD'] = 'POST';
-	require_once $xoops_config->xoops_mainfile_path; //It is necessary to execute it for the user attestation before wp-settings.php. 
-	$_SERVER['REQUEST_METHOD'] = $request_method;
-*/
 	xpress_set_memory_limmit(); // Set memory limmit.(Limmit Value from XPressMe modele config.)
 	unset($offset);		//This Trap is provides the case where $offset is defined on the XOOPS side.
@@ -161,5 +152,5 @@
 		xpress_pulugin_activation('xpressme/xpressme.php');
 		// reloaded 
-		header('Location: ' . $xoops_config->module_url . '/');
+		header('Location: ' . $modInfo->get_module_url() . '/');
 		
 		$err_str = "The activation of the XPressME plugin was executed.<br />\n";
@@ -172,8 +163,5 @@
 	ob_start();
 		$now_ob_level = ob_get_level();
-		if (version_compare($xoops_config->wp_version,'2.2', '<'))
-			require_once dirname( __FILE__ ).'/old_template-loader.php' ;
-		else
-			require_once( ABSPATH . WPINC . '/template-loader.php' );
+		require_once( ABSPATH . WPINC . '/template-loader.php' );
 		ob_end_flush_child($now_ob_level);
 		$wp_output = ob_get_contents();
@@ -202,9 +190,9 @@
 	// This Function in xpressme plugin
 	require_once( dirname( __FILE__ ).'/xpress_block_render.php' );	
-	xpress_unnecessary_block_cache_delete($xoops_config->module_name);
+	xpress_unnecessary_block_cache_delete($modInfo->get_module_dirname());
 	if (is_home()) {
-		xpress_block_cache_refresh($xoops_config->module_name);
+		xpress_block_cache_refresh($modInfo->get_module_dirname());
 		require_once( dirname( __FILE__ ).'/xpress_block_header.php' );	
-		set_xpress_block_header($xoops_config->module_name);
+		set_xpress_block_header($modInfo->get_module_dirname());
 	}
 	if ( ini_get( 'register_globals' ) )
@@ -213,6 +201,4 @@
 	exit();		// The return to wp-blog-header.php is stolen here
 }
-//if (is_admin_post_call()) require_once $xoops_config->xoops_mainfile_path;		// for Notification_triggerEvent
-//if (is_xpress_comments_post_call()) require_once $xoops_config->xoops_mainfile_path;	// for Notification_triggerEvent
 xpress_set_memory_limmit(); // Set memory limmit.(Limmit Value from XPressMe modele config.)
 require_once(ABSPATH.'wp-settings.php');
Index: branches/Ver3.0/xpressme_integration_kit/include/data.inc.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/include/data.inc.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/include/data.inc.php	(revision 757)
@@ -31,13 +31,11 @@
 	global $xoopsDB;
 
+	$module_handler =& xoops_gethandler('module');
+	$module =& $module_handler->getByDirname($mydirname);
+	$module_id = $module->getVar('mid');
+	
 	$wp_prefix = preg_replace('/wordpress/','wp',$mydirname);
 	require_once (XOOPS_ROOT_PATH . '/modules/'.$mydirname . '/include/general_functions.php');
 	include(XOOPS_ROOT_PATH . '/modules/'.$mydirname . '/wp-includes/version.php');
-
-	$modules_table = $xoopsDB->prefix('modules');
-	$modSQL ="SELECT mid FROM " . $modules_table . " WHERE dirname LIKE '" . $mydirname . "'";
-	$modRes = $xoopsDB->query($modSQL, 0, 0);
-	$modRow = $xoopsDB->fetchArray($modRes);
-	$module_id = $modRow['mid'];
 
 	$table_config = $xoopsDB->prefix('config');
Index: branches/Ver3.0/xpressme_integration_kit/include/memory_limit.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/include/memory_limit.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/include/memory_limit.php	(revision 757)
@@ -2,5 +2,4 @@
 	// Set XPressME memory limit
 	function xpress_set_memory_limmit(){
-		global $xoops_config;
 		global $xoopsDB,$xoopsModule,$xoopsModuleConfig;
 		
Index: branches/Ver3.0/xpressme_integration_kit/include/old_template-loader.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/include/old_template-loader.php	(revision 756)
+++ 	(revision )
@@ -1,67 +1,0 @@
-<?php
-if ( defined('WP_USE_THEMES') && constant('WP_USE_THEMES') ) {
-	do_action('template_redirect');
-	if ( is_feed() ) {
-		include(ABSPATH . '/wp-feed.php');
-		return;
-	} else if ( is_trackback() ) {
-		include(ABSPATH . '/wp-trackback.php');
-		return;
-	} else if ( is_404() && $template = get_404_template() ) {
-		include($template);
-		return;
-	} else if ( is_search() && $template = get_search_template() ) {
-		include($template);
-		return;
-	} else if ( is_home() && $template = get_home_template() ) {
-		include($template);
-		return;
-	} else if ( is_attachment() && $template = get_attachment_template() ) {
-		include($template);
-		return;
-	} else if ( is_single() && $template = get_single_template() ) {
-		if ( is_attachment() )
-			add_filter('the_content', 'prepend_attachment');
-		include($template);
-		return;
-	} else if ( is_page() && $template = get_page_template() ) {
-		if ( is_attachment() )
-			add_filter('the_content', 'prepend_attachment');
-		include($template);
-		return;
-	} else if ( is_category() && $template = get_category_template()) {
-		include($template);
-		return;		
-	} else if ( is_author() && $template = get_author_template() ) {
-		include($template);
-		return;
-	} else if ( is_date() && $template = get_date_template() ) {
-		include($template);
-		return;
-	} else if ( is_archive() && $template = get_archive_template() ) {
-		include($template);
-		return;
-	} else if ( is_comments_popup() && $template = get_comments_popup_template() ) {
-		include($template);
-		return;
-	} else if ( is_paged() && $template = get_paged_template() ) {
-		include($template);
-		return;
-	} else if ( file_exists(TEMPLATEPATH . "/index.php") ) {
-		if ( is_attachment() )
-			add_filter('the_content', 'prepend_attachment');
-		include(TEMPLATEPATH . "/index.php");
-		return;
-	}
-} else {
-	// Process feeds and trackbacks even if not using themes.
-	if ( is_feed() ) {
-		include(ABSPATH . '/wp-feed.php');
-		return;
-	} else if ( is_trackback() ) {
-		include(ABSPATH . '/wp-trackback.php');
-		return;
-	}
-}
-
-?>
Index: branches/Ver3.0/xpressme_integration_kit/include/request_url.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/include/request_url.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/include/request_url.php	(revision 757)
@@ -13,5 +13,5 @@
  */
 function check_page_call($check_file =''){
-	global $xoops_config;	// not object at install
+	global $modInfo;	// not object at install
 	if (empty($check_file)) return false;
 	$xpress_page = 	basename(dirname(dirname(__FILE__))) . '/' . $check_file;
Index: branches/Ver3.0/xpressme_integration_kit/include/set_cash_cookie_path.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/include/set_cash_cookie_path.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/include/set_cash_cookie_path.php	(revision 757)
@@ -1,5 +1,5 @@
 <?php
-$modname= $xoops_config->module_name;
-$modurl = $xoops_config->module_url;
+$modname= $modInfo->get_module_dirname();
+$modurl = $modInfo->get_module_url();
 $hash = md5($modurl);
 /**
@@ -50,5 +50,5 @@
  */
 if ( !defined('COOKIEPATH') )
-	define('COOKIEPATH', preg_replace('|https?://[^/]+|i', '', $xoops_config->xoops_url . '/' ) );
+	define('COOKIEPATH', preg_replace('|https?://[^/]+|i', '', $modInfo->get_xoops_url() . '/' ) );
 
 /**
@@ -57,5 +57,5 @@
  */
 if ( !defined('SITECOOKIEPATH') )
-	define('SITECOOKIEPATH', preg_replace('|https?://[^/]+|i', '', $xoops_config->xoops_url  . '/' ) );
+	define('SITECOOKIEPATH', preg_replace('|https?://[^/]+|i', '', $modInfo->get_xoops_url()  . '/' ) );
 
 /**
Index: branches/Ver3.0/xpressme_integration_kit/include/wp_installer.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/include/wp_installer.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/include/wp_installer.php	(revision 757)
@@ -46,5 +46,4 @@
 	//xpress
 	global $wpdb,$wp_rewrite, $wp_queries, $table_prefix, $wp_db_version, $wp_roles, $wp_query,$wp_embed;
-	global $xoops_config;
 	$msgs = array();
 		
@@ -107,6 +106,6 @@
 	
 	// Rewrite Option for Xpress
-	$xoops_config_tbl = XOOPS_DB_PREFIX . '_config' ;
-	$sql = "SELECT conf_value FROM  $xoops_config_tbl WHERE `conf_name` = 'default_TZ'";
+	$xoops_conf_tbl = XOOPS_DB_PREFIX . '_config' ;
+	$sql = "SELECT conf_value FROM  $xoops_conf_tbl WHERE `conf_name` = 'default_TZ'";
 	$xoops_default_TZ = $wpdb->get_var($sql);
 	update_option('gmt_offset', $xoops_default_TZ);	
Index: branches/Ver3.0/xpressme_integration_kit/include/xpress_block_header.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/include/xpress_block_header.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/include/xpress_block_header.php	(revision 757)
@@ -4,9 +4,9 @@
 	require_once dirname( __FILE__ ) .'/xml.php' ;
 	require_once dirname( __FILE__ ) .'/xpress_cache.php' ;
-	global $xoops_config;
+	global $mod_info;
 	
-	if (!is_object($xoops_config)){ // is call other modules
-		require_once dirname(dirname( __FILE__ )) .'/class/config_from_xoops.class.php' ;
-		$xoops_config = new ConfigFromXoops;
+	if (!is_object($mod_info)){ // is call other modules
+		require_once dirname(dirname( __FILE__ )) .'/class/modInfo_class.php' ;
+		$mod_info = new modInfoClass;
 	}
 	
@@ -46,12 +46,12 @@
 	function get_block_stylesheet_url($mydirname)
 	{
-		global $xoops_config;
-		$mydirpath = $xoops_config->xoops_root_path . '/modules/' . $mydirname;
+		global $mod_info;
+		$mydirpath = $mod_info->get_xoops_root_path() . '/modules/' . $mydirname;
 		$select_theme = get_xpress_theme_name($mydirname);
 		$style_file = $mydirpath . '/wp-content/themes/' . $select_theme . '/blocks/block_style.css';
 		if (file_exists($style_file))
-			return $xoops_config->xoops_url . '/modules/' .$mydirname . '/wp-content/themes/' . $select_theme . '/blocks/block_style.css';
+			return $mod_info->get_xoops_url() . '/modules/' .$mydirname . '/wp-content/themes/' . $select_theme . '/blocks/block_style.css';
 		else	
-			return $xoops_config->xoops_url . '/modules/' .$mydirname . '/wp-content/themes/xpress_default/blocks/block_style.css';
+			return $mod_info->get_xoops_url() . '/modules/' .$mydirname . '/wp-content/themes/xpress_default/blocks/block_style.css';
 	}
 
Index: branches/Ver3.0/xpressme_integration_kit/include/xpress_block_render.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/include/xpress_block_render.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/include/xpress_block_render.php	(revision 757)
@@ -4,9 +4,9 @@
 	require_once dirname( __FILE__ ) .'/xml.php' ;
 	require_once dirname( __FILE__ ) .'/xpress_cache.php' ;
-	global $xoops_config;
-	
-	if (!is_object($xoops_config)){ // is call other modules
-		require_once dirname(dirname( __FILE__ )) .'/class/config_from_xoops.class.php' ;
-		$xoops_config = new ConfigFromXoops;
+	global $modInfo;
+	
+	if (!is_object($modInfo)){ // is call other modules
+		require_once dirname(dirname( __FILE__ )) .'/class/modInfo_class.php' ;
+		$modInfo = new modInfoClass;
 	}
 	
@@ -68,13 +68,8 @@
 	{
 		global $xoopsDB;
-			$modules_tbl = $xoopsDB->prefix('modules');
-
-			$sql = "SELECT mid FROM $modules_tbl WHERE dirname = '$mydirname'";
-			$result =  $xoopsDB->query($sql, 0, 0);
-			if ($xoopsDB->getRowsNum($result)  > 0){
-				$row = $xoopsDB->fetchArray($result);
-				$mid = $row['mid'];
-			}
-			return $mid;
+		$module_handler =& xoops_gethandler('module');
+		$module =& $module_handler->getByDirname($mydirname);
+		$module_id = $module->getVar('mid');
+		return $module_id;
 	}
 
@@ -121,7 +116,7 @@
     function xpress_block_cache_found($mydirname,$block_name)
     {
-    	global $xoops_config;
+    	global $modInfo;
     	
-		$cache_dir = $xoops_config->xoops_cache_path . '/';
+		$cache_dir = $modInfo->get_xoops_cache_path() . '/';
     	$xml_name = $block_name . '.xml';
 
@@ -138,5 +133,5 @@
 	function xpress_block_render($mydirname,$block_function_name,$options)
 	{
-		global $wpdb,$xoops_config,$xoopsUserIsAdmin;
+		global $wpdb,$modInfo,$xoopsUserIsAdmin;
 		$func_file = $block_function_name;
 		$call_theme_function_name = str_replace(".php", "", $block_function_name);
@@ -183,7 +178,7 @@
 		
 		$tpl =& new XoopsTpl() ;
-		$tpl->template_dir = $xoops_config->module_path . '/templates';
+		$tpl->template_dir = $modInfo->get_module_templates_path();
 		if (!$tpl->template_exists($templates_file)){
-			$src_file_path = $xoops_config->module_path . '/templates/' .$mydirname. '_' . str_replace(".php", ".html", $block_function_name);
+			$src_file_path = $modInfo->get_module_templates_path() . '/' .$mydirname. '_' . str_replace(".php", ".html", $block_function_name);
 			$templates_file = add_xpress_tpl($mydirname,$templates_file,$src_file_path);
 		}
@@ -198,5 +193,5 @@
 	
 	function add_xpress_tpl($mydirname,$templates='',$src_file_path){
-		global $wpdb,$xoops_config , $xoops_db;
+		global $wpdb,$modInfo , $xoops_db;
 		
 		$mid = get_block_mid($mydirname);
@@ -210,5 +205,5 @@
 			$type = $temp_parm[0];
 		}
-		$temp_file_path = $xoops_config->module_path . '/templates/'. $filename;
+		$temp_file_path = $modInfo->get_module_templates_path() . '/'. $filename;
 		$pattern = '^' . $mydirname . '_';
 		if (preg_match('/' . $pattern . '/' , $filename, $match)){ // file prefix check
@@ -274,5 +269,5 @@
 	function xpress_unnecessary_block_cache_delete($mydirname)
 	{
-		global $xoops_db,$xoops_config;
+		global $xoops_db,$modInfo;
 		
 		$mid = get_xpress_modid();
@@ -289,5 +284,5 @@
 		$pattern = '(' . $pattern . ')';
 		
-		$cache_dir = $xoops_config->xoops_cache_path . '/';
+		$cache_dir = $modInfo->get_xoops_cache_path() . '/';
 		$cache_time = 0;
         if ($dh = opendir($cache_dir)) {
Index: branches/Ver3.0/xpressme_integration_kit/include/xpress_cache.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/include/xpress_cache.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/include/xpress_cache.php	(revision 757)
@@ -4,6 +4,6 @@
 if(!function_exists("cache_is_writable")):
 	function cache_is_writable(){
-		global $xoops_config;
-		$cache_dir = $xoops_config->xoops_cache_path . '/';
+		global $modInfo;
+		$cache_dir = $modInfo->get_xoops_cache_path() . '/';
 		$filename = $cache_dir .'xpress_cache_test.txt';
 		$fp = @fopen($filename, "w");
@@ -30,7 +30,7 @@
     function xpress_cache_read($mydirname,$collation_key)
     {
-    	global $xoops_config;
+    	global $modInfo;
     	
-    	$cache_dir = $xoops_config->xoops_cache_path . '/';
+    	$cache_dir = $modInfo->get_xoops_cache_path() . '/';
         $filename = $cache_dir .$mydirname . '_' . $collation_key;
         if (xpress_cache_found($filename)) {
@@ -45,6 +45,6 @@
     function xpress_cache_write($mydirname,$collation_key,$content)
     {
-		global $xoops_config;
-		$cache_dir = $xoops_config->xoops_cache_path . '/';
+		global $modInfo;
+		$cache_dir = $modInfo->get_xoops_cache_path() . '/';
 		$cache_time = 0;
 
@@ -62,6 +62,6 @@
     function xpress_cache_clear($mydirname)
     {
-		global $xoops_config;
-		$cache_dir = $xoops_config->xoops_cache_path . '/';
+		global $modInfo;
+		$cache_dir = $modInfo->get_xoops_cache_path() . '/';
 		$cache_time = 0;
         if ($dh = opendir($cache_dir)) {
Index: branches/Ver3.0/xpressme_integration_kit/include/xpress_render.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/include/xpress_render.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/include/xpress_render.php	(revision 757)
@@ -182,5 +182,5 @@
 //rendering for the module header and the body
 function xpress_render($contents){
-	global $xoops_config;
+	global $modInfo;
 	global $xoopsUser , $xoopsTpl,$xpress_config , $xoopsModule , $xoopsLogger, $xoopsConfig ; //for XOOPS
 	
@@ -190,5 +190,5 @@
 	xpress_remake_global_for_permlink();
 	$mydirname = basename(dirname(dirname(__FILE__)));
-	include $xoops_config->xoops_root_path ."/header.php";
+	include $modInfo->get_xoops_header_path();
 	$xoopsTpl->assign('xoops_breadcrumbs', $xoops_breadcrumbs);
 	$xoopsTpl->assign('xoops_module_header', get_xpress_module_header($contents));
@@ -265,5 +265,5 @@
 	//If notification_select.php is not executed in CMS other than XCL, the selector of in-line is not displayed. 
 	if (is_object($xoopsModule) && $xoopsModule->getVar('hasnotification') == 1 && is_object($xoopsUser)) {
-		require_once $xoops_config->xoops_root_path . '/include/notification_select.php';
+		require_once $modInfo->get_xoops_root_path() . '/include/notification_select.php';
 	}
 	
@@ -272,5 +272,5 @@
 	$xoopsTpl->clear_cache($templates_file);
 	echo $xoopsTpl->fetch( $templates_file ) ;
-	include $xoops_config->xoops_root_path . '/footer.php';
+	include $modInfo->get_xoops_footer_path();
 }
 
Index: branches/Ver3.0/xpressme_integration_kit/wp-config.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/wp-config.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/wp-config.php	(revision 757)
@@ -18,14 +18,14 @@
 
 /** Do not change. The name of the database for WordPress */
-define('DB_NAME', $xoops_config->xoops_db_name);
+define('DB_NAME', $wpConfigInfo->get_db_name() );
 
 /** Do not change. MySQL database username */
-define('DB_USER', $xoops_config->xoops_db_user);
+define('DB_USER', $wpConfigInfo->get_db_user() );
 
 /** Do not change. MySQL database password */
-define('DB_PASSWORD', $xoops_config->xoops_db_pass);
+define('DB_PASSWORD', $wpConfigInfo->get_db_pass() );
 
 /** Do not change. MySQL hostname */
-define('DB_HOST', $xoops_config->xoops_db_host);
+define('DB_HOST', $wpConfigInfo->get_db_host() );
 	
 /** Database Charset to use in creating database tables. */
@@ -61,5 +61,5 @@
  */
 // Do not change. $table_prefix is generated from XOOPS DB Priefix and the module directory name. 
-$table_prefix  = $xoops_config->module_db_prefix;
+$table_prefix  = $wpConfigInfo->get_db_prefix();
 
 /**
@@ -75,5 +75,5 @@
  * define ('WPLANG', 'ja');		// language support to Japanese
  */
-define ('WPLANG', $xoops_config->wp_lang);		// language detect from xoops language
+define ('WPLANG', $wpConfigInfo->get_wpLang() );		// language detect from xoops language
 
 /* That's all, stop editing! Happy blogging. */
Index: branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/custom_functions.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/custom_functions.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/custom_functions.php	(revision 757)
@@ -40,6 +40,4 @@
 
 function xpress_is_multiblog() {
-	global $xoops_config;
-	
 	if (function_exists('is_multisite') && is_multisite()) return true;
 	return false;
@@ -56,6 +54,6 @@
 
 function xpress_is_wp_version($operator='==',$comp_version){
-	global $xoops_config;
- 	return version_compare($xoops_config->wp_version, $comp_version, $operator);
+	global $modInfo;
+ 	return version_compare($modInfo->get_wp_version(), $comp_version, $operator);
 }
 
@@ -184,8 +182,5 @@
 function xpress_credit($args ='')
 {
-	global $wp_version , $xoops_config;
-	if ($xoops_config->is_wpmu) {
-		global $wpmu_version;
-	}
+	global $wp_version , $modInfo;
 	
 	$defaults = array(
@@ -197,29 +192,19 @@
 	extract( $r );
 	
-	$xpress_version = $xoops_config->module_version;
-	$xpress_codename = $xoops_config->module_codename;
+	$xpress_version = $modInfo->get_module_version();
+	$xpress_codename = $modInfo->get_module_codename();
 	if ($no_link){
-		if ($xoops_config->is_wpmu) {
-			$output = 'XPressMU Ver.' . sprintf('%.2f %s',$xpress_version,$xpress_codename);
-			$output .= '(included WordPress MU ' . $wpmu_version. ')';
+		$output = 'XPressME Ver.' . sprintf('%.2f %s',$xpress_version,$xpress_codename);
+		if (strstr($wp_version,'ME')){
+			$output .= '(included WordPress ' . $wp_version . ')';
 		} else {
-			$output = 'XPressME Ver.' . sprintf('%.2f %s',$xpress_version,$xpress_codename);
-			if (strstr($wp_version,'ME')){
-				$output .= '(included WordPress ' . $wp_version . ')';
-			} else {
-				$output .= '(included WordPress ' . $wp_version . ')';
-			}
-		}
-	} else {
-		if ($xoops_config->is_wpmu) {
-			$output = '<a href="http://ja.xpressme.info"'. " target='_blank'" . '>XPressMU Ver.' . sprintf('%.2f %s',$xpress_version,$xpress_codename) .'</a>';
-			$output .= '(included <a href="http://mu.wordpress.org/" title="Powered by WordPress"'." target='_blank'". '>WordPress MU ' . $wpmu_version . '</a>)';
+			$output .= '(included WordPress ' . $wp_version . ')';
+		}
+	} else {
+		$output = '<a href="http://ja.xpressme.info"'. " target='_blank'" . '>XPressME Ver.' . sprintf('%.2f %s',$xpress_version,$xpress_codename) .'</a>';
+		if (strstr($wp_version,'ME')){
+			$output .= '(included <a href="http://wpme.sourceforge.jp/" title="Powered by WordPress"'." target='_blank'". '>WordPress ' . $wp_version . '</a>)';
 		} else {
-			$output = '<a href="http://ja.xpressme.info"'. " target='_blank'" . '>XPressME Ver.' . sprintf('%.2f %s',$xpress_version,$xpress_codename) .'</a>';
-			if (strstr($wp_version,'ME')){
-				$output .= '(included <a href="http://wpme.sourceforge.jp/" title="Powered by WordPress"'." target='_blank'". '>WordPress ' . $wp_version . '</a>)';
-			} else {
-				$output .= '(included <a href="http://wordpress.org/" title="Powered by WordPress"'." target='_blank'". '>WordPress ' . $wp_version . '</a>)';
-			}
+			$output .= '(included <a href="http://wordpress.org/" title="Powered by WordPress"'." target='_blank'". '>WordPress ' . $wp_version . '</a>)';
 		}
 	}		
@@ -664,5 +649,5 @@
 function xpress_post_new_link($args ='')
 {
-	global $xoops_config;
+	global $modInfo;
 	
 	$defaults = array(
@@ -846,5 +831,5 @@
 
 function xpress_get_calendar($args = '') {
-	global $wpdb, $m, $monthnum, $year, $wp_locale, $posts , $xoops_config;
+	global $wpdb, $m, $monthnum, $year, $wp_locale, $posts , $modInfo;
 
 	$defaults = array(
@@ -1035,5 +1020,5 @@
 
 function xpress_create_new_blog_link($args ='' ) {
-	global $xoops_config;
+	global $modInfo;
 
 	global $current_user;
@@ -1058,5 +1043,5 @@
 
 function xpress_create_new_blog() {
-	global $xoops_config;
+	global $modInfo;
 	global $current_user;
 	$ret = array();
@@ -1070,5 +1055,5 @@
 			case 'all':
 			case 'blog':
-				$ret['url'] = $xoops_config->module_url . '/wp-signup.php';
+				$ret['url'] = $modInfo->get_module_url() . '/wp-signup.php';
 				$ret['menu_url'] = 'wp-signup.php';
 				$ret['title'] = __('Create New Blog','xpressme');
@@ -1083,5 +1068,5 @@
 }
 function xpress_primary_blog_link() {
-	global $xoops_config;
+	global $modInfo;
 	global $current_user;
 	global $blog_id;
Index: branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/d3forum_comment_synchro.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/d3forum_comment_synchro.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/d3forum_comment_synchro.php	(revision 757)
@@ -524,10 +524,10 @@
 //  The content is reflected in the D3Forum comment when there is a change in the WordPress comment. 
 function wp_comment_sync_to_d3forum($comment_ID = 0,$sync_mode){
-	global $xpress_config,$xoops_db,$xoops_config,$wpdb,$blog_id;
+	global $xpress_config,$xoops_db,$modInfo,$wpdb,$blog_id;
 	
 	if (empty($blog_id)) $blog_id =1;
 	
 	if (!is_d3forum_setting()) die('The setting of the D3Forum comment integration is wrong. ');
-	$mydirname = $xoops_config->module_name;
+	$mydirname = $modInfo->get_module_dirname();
 
 	$d3f_forum_id = $xpress_config->d3forum_forum_id;
Index: branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/functions_for_wp_old.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/functions_for_wp_old.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/functions_for_wp_old.php	(revision 757)
@@ -1,5 +1,5 @@
 <?php
 // wp_login override for wp2.3 under
-if ( !function_exists('wp_login') && version_compare($xoops_config->wp_version,'2.3', '<')) :
+if ( !function_exists('wp_login') && version_compare($modInfo->get_wp_version(),'2.3', '<')) :
 	function wp_login($username, $password, $already_md5 = false) {
 		global $wpdb, $error;
@@ -43,5 +43,5 @@
 
 // Under WP2.1
-if (version_compare($xoops_config->wp_version,'2.1', '<')) :
+if (version_compare($modInfo->get_wp_version(),'2.1', '<')) :
 	// ADD WP 2.1.0
 	function the_modified_date($d = '') {
@@ -60,5 +60,5 @@
 
 // Under WP2.2
-if (version_compare($xoops_config->wp_version,'2.2', '<')):
+if (version_compare($modInfo->get_wp_version(),'2.2', '<')):
 	// Added WP2.2 wp_parse_args()
 	function wp_parse_args( $args, $defaults = '' ) {
@@ -95,5 +95,5 @@
 
 // Under WP2.2.1
-if (version_compare($xoops_config->wp_version,'2.2.1', '<')) :
+if (version_compare($modInfo->get_wp_version(),'2.2.1', '<')) :
 	// Added WP2.2.1 wp_parse_str()
 	function wp_parse_str( $string, &$array ) {
@@ -107,5 +107,5 @@
 
 // Under WP2.3
-if (version_compare($xoops_config->wp_version,'2.3', '<')) :
+if (version_compare($modInfo->get_wp_version(),'2.3', '<')) :
 	if ( !function_exists('wp_sanitize_redirect') ) :
 	/**
@@ -167,5 +167,5 @@
 
 // Under WP2.5
-if (version_compare($xoops_config->wp_version,'2.5', '<')) :
+if (version_compare($modInfo->get_wp_version(),'2.5', '<')) :
 	// Added WP2.5 absint()
 	function absint( $maybeint ) {
@@ -192,5 +192,5 @@
 
 // Under WP2.7
-if (version_compare($xoops_config->wp_version,'2.6', '<')) :
+if (version_compare($modInfo->get_wp_version(),'2.6', '<')) :
 	/**
 	 * Guess the URL for the site.
@@ -215,5 +215,5 @@
 
 // Under WP2.7
-if (version_compare($xoops_config->wp_version,'2.7', '<')) :
+if (version_compare($modInfo->get_wp_version(),'2.7', '<')) :
 	// Added WP2.7 separate_comments()
 	function &separate_comments(&$comments) {
@@ -346,5 +346,5 @@
 
 // Under WP2.8
-if (version_compare($xoops_config->wp_version,'2.8', '<')) :
+if (version_compare($modInfo->get_wp_version(),'2.8', '<')) :
 	function _wp_specialchars( $string, $quote_style = ENT_NOQUOTES, $charset = false, $double_encode = false ) {
 		$string = (string) $string;
Index: branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/notify_functions.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/notify_functions.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/notify_functions.php	(revision 757)
@@ -37,5 +37,5 @@
 function Notification_triggerEvent($force_reserve = false,$category, $item_id, $event, $extra_tags=array(), $user_list=array(), $omit_user_id=null)
 {
-	global $xoops_db,$xoops_config;
+	global $xoops_db,$modInfo;
 	global $xoopsModule,$xoopsUser,$xoopsUserIsAdmin;
 
@@ -52,10 +52,4 @@
 		$_SERVER['REQUEST_METHOD'] = 'POST';
 	}
-//	set_error_handler("xpress_error_handler");
-//	if ($xoops_config->is_impress != true){  // impress cms is error
-//		if ( !defined("XOOPS_MAINFILE_INCLUDED")) {
-//			require_once $xoops_config->xoops_mainfile_path;	// load XOOPS System
-//		}
-//	}
 	if (!$force_reserve && defined("XOOPS_MAINFILE_INCLUDED") ) {
 		if ( defined("XPRESS_EVENT_DEBUG")) xpress_debug_message($message = 'call $notification_handler->triggerEvent');
@@ -85,5 +79,5 @@
 function do_CommentNotifications($commentID, $comment_post_ID)
 {
-	global $wpdb, $xoops_config , $xoops_db;
+	global $wpdb, $modInfo , $xoops_db;
 
 	$table_term_relationships = $wpdb->term_relationships;
@@ -139,5 +133,5 @@
 function do_PostNotifications($post_id,$not_event)
 {
-	global $wpdb, $xoops_config, $xoops_db;
+	global $wpdb, $modInfo, $xoops_db;
 
 	 // $not_event:		newpost,editpost ; $commentID, $comment_post_ID)
Index: branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/pluggable-override.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/pluggable-override.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/pluggable-override.php	(revision 757)
@@ -160,5 +160,5 @@
 function wp_check_password($password, $hash, $user_id = '') {
 	global $wp_hasher;
-	global $xoops_config,$xoops_db;
+	global $modInfo,$wpConfigInfo,$xoops_db;
 
 	// For attestation when password has been sent as hash value. (When having logged it in from Xoops and ImpressCMS)
@@ -174,9 +174,9 @@
 	
 	// Password authentication for ImpressCMS 
-	if($xoops_config->is_impress && function_exists('hash')){
-		$mainSalt = $xoops_config->xoops_db_salt;
+	if($modInfo->is_impress_cms() && function_exists('hash')){
+		$mainSalt = $wpConfigInfo->get_db_salt();
 		// get user salt
-		$xpress_user_db = $xoops_config->module_db_prefix . 'users';
-		$xoops_user_db = $xoops_config->xoops_db_prefix . '_users';
+		$xpress_user_db = $wpConfigInfo->get_db_prefix() . 'users';
+		$xoops_user_db = $wpConfigInfo->get_xoops_db_prefix() . 'users';
 		$login_name = $xoops_db->get_var("SELECT user_login FROM $xpress_user_db WHERE ID = $user_id");
 		$user_salt = $xoops_db->get_var("SELECT salt FROM $xoops_user_db WHERE uname = '$login_name'");
@@ -236,9 +236,9 @@
 if ( !function_exists('wp_redirect') ) :
 function wp_redirect($location, $status = 302) {
-	global $is_IIS,$xoops_config,$action;
+	global $is_IIS,$modInfo,$action;
 	
-	if ($location == 'wp-login.php?loggedout=true') $location = $xoops_config->xoops_url.'/user.php?op=logout'; //xoops logout at wp logout
-	if ($location == 'wp-login.php?action=register') $location = $xoops_config->xoops_url."/register.php";  //wp-register to xoops register
-	if ($action == 'logout') $location = $xoops_config->xoops_url.'/user.php?op=logout'; //xoops logout at comment logout
+	if ($location == 'wp-login.php?loggedout=true') $location = $modInfo->get_xoops_url().'/user.php?op=logout'; //xoops logout at wp logout
+	if ($location == 'wp-login.php?action=register') $location = $modInfo->get_xoops_url()."/register.php";  //wp-register to xoops register
+	if ($action == 'logout') $location = $modInfo->get_xoops_url().'/user.php?op=logout'; //xoops logout at comment logout
 
 	$location = apply_filters('wp_redirect', $location, $status);
Index: branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/xpress_common_functions.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/xpress_common_functions.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/xpress_common_functions.php	(revision 757)
@@ -1,7 +1,7 @@
 <?php
-global $xoops_config;
-if (!is_object($xoops_config)){ // is call other modules
-	require_once dirname(dirname(dirname(dirname(dirname( __FILE__ ))))) .'/class/config_from_xoops.class.php' ;
-	$xoops_config = new ConfigFromXoops;
+global $modInfo;
+if (!is_object($modInfo)){ // is call other modules
+	require_once dirname(dirname(dirname(dirname(dirname( __FILE__ ))))) .'/class/modInfoClass.php' ;
+	$modInfo = new ConfigFromXoops;
 }
 
@@ -14,8 +14,9 @@
 	global $xoops_db;
 	
-	$modules_db = get_xoops_prefix() . 'modules';
+	$module_handler =& xoops_gethandler('module');
+	$module =& $module_handler->getByDirname($mydirname);
+	$moduleID = $module->getVar('mid');
+
 	$config_db = get_xoops_prefix() . 'config';
-
-	$moduleID = $xoops_db->get_var("SELECT mid FROM $modules_db WHERE dirname = '$module_dir'");
 	if (empty($moduleID)) return null;
 	$conf_value = $xoops_db->get_var("SELECT conf_value FROM $config_db WHERE (conf_modid = $moduleID) AND (conf_name = '$config_name')");
@@ -46,6 +47,6 @@
 function get_xoops_prefix()
 {
-	global $xoops_config;
-	$ret =$xoops_config->xoops_db_prefix . '_';
+	global $modInfo;
+	$ret = $modInfo->get_xoops_db_prefix();
 	return $ret;
 }
@@ -53,6 +54,6 @@
 function get_xoops_trust_path()
 {
-	global $xoops_config;
-	$ret =$xoops_config->xoops_trust_path;
+	global $modInfo;
+	$ret =$modInfo->get_xoops_trust_path();
 	return $ret;
 }
@@ -60,6 +61,6 @@
 function get_xoops_root_path()
 {
-	global $xoops_config;
-	$ret =$xoops_config->xoops_root_path;
+	global $modInfo;
+	$ret =$modInfo->get_xoops_root_path();
 	return $ret;
 }
@@ -72,6 +73,6 @@
 function get_xoops_url()
 {
-	global $xoops_config;
-	$ret =$xoops_config->xoops_url ;
+	global $modInfo;
+	$ret =$modInfo->get_xoops_url() ;
 	return $ret;
 }
@@ -79,6 +80,6 @@
 function get_xpress_url()
 {
-	global $xoops_config;
-	$ret =$xoops_config->module_url ;
+	global $modInfo;
+	$ret =$modInfo->get_module_url() ;
 	return $ret;
 }
@@ -86,10 +87,9 @@
 function get_xpress_modid()
 {
-	global $xoops_db;
-	
-	$modulename = get_xpress_dir_name();	
-	$sql = "SELECT mid FROM " . get_xoops_prefix() . "modules WHERE dirname = '$modulename'";
-	$mid = $xoops_db->get_var($sql);
-	return $mid;	
+	global $modInfo;
+	
+	$modulename = get_xpress_dir_name();
+	$mid = $modInfo->get_moduleID_ByDirname($modulename);
+	return $mid;
 }
 
@@ -369,6 +369,6 @@
 function get_block_file_path($mydirname,$file_name)
 {
-	global $xoops_config, $xpress_config;
-	$mydirpath = $xoops_config->xoops_root_path . '/modules/' . $mydirname;
+	global $modInfo, $xpress_config;
+	$mydirpath = $modInfo->get_xoops_root_path() . '/modules/' . $mydirname;
 	$select_theme = xpress_ThemeTemplate(get_xpress_theme_name($mydirname));
 	$xpress_default_theme = 'xpress_default';
Index: branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/xpress_upgrade.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/xpress_upgrade.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/xpress_upgrade.php	(revision 757)
@@ -6,7 +6,7 @@
 
 function list_xpress_update( $update=null ) {
-	global $xoops_config,$xpress_config;
-	
-	$xpress_version = $xoops_config->module_version . $xoops_config->module_codename;
+	global $modInfo,$xpress_config;
+	
+	$xpress_version = $modInfo->get_module_full_version();
 	$lang = WPLANG;
 	
@@ -139,5 +139,5 @@
 
 function do_xpress_upgrade( $develop = false,$reinstall = false ) {
-	global $wp_filesystem,$xoops_config;
+	global $wp_filesystem,$modInfo;
 
 	if ( $reinstall )
@@ -191,5 +191,5 @@
 		show_message( __('Please update the module. ', 'xpressme') );
 		
-		$update_url = $xoops_config->module_url .'/admin/update.php';
+		$update_url = $modInfo->get_module_url() .'/admin/update.php';
 		show_message( '<strong>' . __('Actions:', 'xpressme') . '</strong> <a href="' . esc_url( $update_url ) . '">' . __('Go to Module Update', 'xpressme') . '</a>' );
 	}
@@ -216,8 +216,8 @@
 
 function xp_remote_get($url, $headers = ""){
-	global $xoops_config;
-	$xpress_version = $xoops_config->module_version . $xoops_config->module_codename;
-
-	require_once( $xoops_config->module_path . '/wp-includes/class-snoopy.php');
+	global $modInfo;
+	$xpress_version = $modInfo->get_module_full_version();
+
+	require_once( $modInfo->get_module_path() . '/wp-includes/class-snoopy.php');
 
 	// Snoopy is an HTTP client in PHP
@@ -263,7 +263,7 @@
 function get_xpress_latest_version($check_url=null){
 	global $wp_version, $wpdb, $wp_local_package;
-	global $xoops_config;
-	
-	$xpress_version = $xoops_config->module_version . $xoops_config->module_codename;
+	global $modInfo;
+	
+	$xpress_version = $modInfo->get_module_full_version();
 	$lang = WPLANG;
 	if(is_null($check_url))
@@ -362,8 +362,8 @@
 
 	global $wp_version, $wpdb, $wp_local_package;
-	global $xoops_config;
+	global $modInfo;
 
 	$php_query_string = $_SERVER['QUERY_STRING'];
-	$xpress_version = $xoops_config->module_version . $xoops_config->module_codename;
+	$xpress_version = $modInfo->get_module_full_version();
 
 	$latest = get_option('xpressme_latest_version');
@@ -387,5 +387,5 @@
 		$latest_version=$latest['latest_version'];
 		$check_time=$latest['check_time'];
-		$upgrade_page = $xoops_config->module_url . "/wp-admin/admin.php?page=upgrade_page";
+		$upgrade_page = $modInfo->get_module_url() . "/wp-admin/admin.php?page=upgrade_page";
 
 		if (version_compare($xpress_version, $latest_version, '<')) {
Index: branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/xpressme.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/xpressme.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/xpressme.php	(revision 757)
@@ -50,5 +50,5 @@
 function my_plugin_menu()
 {
-	global $xpress_config,$xoops_config;
+	global $xpress_config,$modInfo;
 	
 	$plugin_url = WP_PLUGIN_URL."/xpressme/";
@@ -172,6 +172,6 @@
 function redirect_xoops_admin()
 {
-	global $xoops_config,$xpress_config;
-	$xoops_admin_url = $xoops_config->module_url . '/admin/index.php';
+	global $modInfo,$xpress_config;
+	$xoops_admin_url = $modInfo->get_module_url() . '/admin/index.php';
 	wp_redirect($xoops_admin_url);
 }
@@ -179,7 +179,7 @@
 function display_option_page()
 {
-	global $xoops_config,$xpress_config;
-	
-		$xoops_admin_url = $xoops_config->module_url . '/admin/index.php';
+	global $modInfo,$xpress_config;
+	
+		$xoops_admin_url = $modInfo->get_module_url() . '/admin/index.php';
 
 		$do_message ='';
@@ -221,7 +221,7 @@
 function integration_option_page()
 {
-	global $xoops_config,$xpress_config,$blog_id;
-	
-		$xoops_admin_url = $xoops_config->module_url . '/admin/index.php';
+	global $modInfo,$xpress_config,$blog_id;
+	
+		$xoops_admin_url = $modInfo->get_module_url() . '/admin/index.php';
 
 		$do_message ='';
@@ -256,5 +256,5 @@
 											false
 											);
-//		$lock = ($xoops_config->module_url != get_bloginfo('url'));
+//		$lock = ($modInfo->get_module_url() != get_bloginfo('url'));
 		$lock = false;
 		echo				$xpress_config->groupe_role_option($lock);	
@@ -273,7 +273,7 @@
 function other_option_page()
 {
-	global $xoops_config,$xpress_config;
-	
-		$xoops_admin_url = $xoops_config->module_url . '/admin/index.php';
+	global $modInfo,$xpress_config;
+	
+		$xoops_admin_url = $modInfo->get_module_url() . '/admin/index.php';
 
 		$do_message ='';
Index: branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/xpressme_class.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/xpressme_class.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/xpressme_class.php	(revision 757)
@@ -55,5 +55,5 @@
 	function setDefault()
 	{
-		global $xoops_config;
+		global $modInfo;
 		$this->is_use_xoops_upload_path = true;
 		$this->is_use_xoops_upload_path = true;
@@ -117,5 +117,5 @@
 	function SettingValueWrite($mode)
 	{
-		global $xoops_config;
+		global $modInfo;
 
 		$write_options = array (
@@ -442,5 +442,5 @@
 		} // end of loop
 
-		global $xoops_config;
+		global $modInfo;
 
 		$table = get_wp_prefix() . 'group_role';	
@@ -788,5 +788,5 @@
 	
 	function d3forum_option($do_message = ''){
-		global $xoops_db,$xoops_config;
+		global $xoops_db,$modInfo;
 		
 		$multi_blog_use_d3forum = true;
@@ -809,5 +809,5 @@
 			// Form making for forum selection of D3forum
 			$modules_table = get_xoops_prefix() .'modules';
-			$sql = "SELECT mid,name,isactive,dirname FROM $modules_table WHERE isactive = 1";
+			$sql = "SELECT name,isactive,dirname FROM $modules_table WHERE isactive = 1";
 			$modules = $xoops_db->get_results($sql);
 			foreach ($modules as $module) {
@@ -1051,16 +1051,16 @@
 	function xpress_upload_filter($uploads)
 	{
-		global $xoops_config;
+		global $modInfo;
 		global $blog_id,$blogname;
 		
 		if ($this->is_use_xoops_upload_path){
 			$wordpress_dir = ABSPATH ;
-			$xoops_dir = $xoops_config->xoops_upload_path . '/';
+			$xoops_dir = $modInfo->get_xoops_upload_path() . '/';
 			if (xpress_is_multiblog() && $blog_id <> BLOG_ID_CURRENT_SITE){
-				$wordpress_base_url = $xoops_config->module_url;
+				$wordpress_base_url = $modInfo->get_module_url();
 			} else {
 				$wordpress_base_url = get_option( 'siteurl' );
 			}
-			$xoops_upload_url = $xoops_config->xoops_upload_url;
+			$xoops_upload_url = $modInfo->get_xoops_upload_url();
 			// @rmdir($uploads[path]);  //remove wordpress side uploads_dir 
 			
Index: branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/xpressme_widget_class.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/xpressme_widget_class.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/xpressme_widget_class.php	(revision 757)
@@ -21,5 +21,5 @@
 	*/
 	function widget($args, $instance){
-		global $xpress_config,$xoops_config;
+		global $xpress_config,$modInfo;
 		global $current_user;
 
@@ -129,5 +129,5 @@
 	*/
 	function form($instance){
-		global $xpress_config,$xoops_config;
+		global $xpress_config,$modInfo;
 		
 		if (xpress_is_wp_version('<','2.1') ){
Index: branches/Ver3.0/xpressme_integration_kit/xoops_version.php
===================================================================
--- branches/Ver3.0/xpressme_integration_kit/xoops_version.php	(revision 756)
+++ branches/Ver3.0/xpressme_integration_kit/xoops_version.php	(revision 757)
@@ -137,5 +137,5 @@
 
 	if(is_object($GLOBALS["xoopsUser"])){
-		global $current_user , $xoops_config;
+		global $current_user;
 		if (mod_access_level() > 0) {
 		$modversion['sub'][1]['name'] = constant( '_MI_XP2_MENU_POST_NEW');
