Changeset 583 for trunk/xpressme_integration_kit/include
- Timestamp:
- Apr 23, 2010, 10:49:33 AM (15 years ago)
- Location:
- trunk/xpressme_integration_kit/include
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/xpressme_integration_kit/include/data.inc.php
r426 r583 31 31 global $xoopsDB; 32 32 33 if ($mydirname == 'wordpress'){ 34 $wp_prefix = 'wp'; 35 } else { 36 $wp_prefix = $mydirname; 37 } 33 $wp_prefix = preg_replace('/wordpress/','wp',$mydirname); 38 34 require_once (XOOPS_ROOT_PATH . '/modules/'.$mydirname . '/include/general_functions.php'); 39 35 include(XOOPS_ROOT_PATH . '/modules/'.$mydirname . '/wp-includes/version.php'); … … 163 159 164 160 global $xoopsDB; 165 166 if ($mydirname == 'wordpress'){ 167 $wp_prefix = 'wp'; 168 } else { 169 $wp_prefix = $mydirname; 170 } 161 $wp_prefix = preg_replace('/wordpress/','wp',$mydirname); 171 162 require_once (XOOPS_ROOT_PATH . '/modules/'.$mydirname . '/include/general_functions.php'); 172 163 $prefix = $xoopsDB->prefix($wp_prefix); … … 208 199 209 200 global $xoopsDB; 210 211 if ($mydirname == 'wordpress'){ 212 $wp_prefix = 'wp'; 213 } else { 214 $wp_prefix = $mydirname; 215 } 201 $wp_prefix = preg_replace('/wordpress/','wp',$mydirname); 216 202 217 203 require_once (XOOPS_ROOT_PATH . '/modules/'.$mydirname . '/include/general_functions.php'); -
trunk/xpressme_integration_kit/include/general_functions.php
r526 r583 13 13 if (empty($mydirname)) 14 14 $mydirname = basename( dirname( dirname( __FILE__ ) ) ) ; 15 16 if ($mydirname == 'wordpress'){ 17 $wp_prefix = 'wp'; 18 } else { 19 $wp_prefix = $mydirname; 20 } 15 16 $wp_prefix = preg_replace('/wordpress/','wp',$mydirname); 21 17 22 18 if (empty($xoops_db)) { // not load XPressME … … 56 52 $mydirname = basename( dirname( dirname( __FILE__ ) ) ) ; 57 53 58 if ($mydirname == 'wordpress'){ 59 $wp_prefix = 'wp'; 60 } else { 61 $wp_prefix = $mydirname; 62 } 54 $wp_prefix = preg_replace('/wordpress/','wp',$mydirname); 63 55 64 56 if (empty($xoops_db)) { // not load XPressME -
trunk/xpressme_integration_kit/include/oninstall.php
r534 r583 86 86 87 87 // create XPressME table 88 $xp_prefix = $mydirname; 89 if ($xp_prefix == 'wordpress'){ 90 $xp_prefix = 'wp'; 91 } 88 $xp_prefix = preg_replace('/wordpress/','wp',$mydirname); 92 89 $views_table = XOOPS_DB_PREFIX . '_' . $xp_prefix .'_views' ; 93 90 -
trunk/xpressme_integration_kit/include/onuninstall.php
r232 r583 25 25 $mid = $module->getVar('mid') ; 26 26 27 $xp_prefix = $mydirname; 28 if ($xp_prefix == 'wordpress'){ 29 $xp_prefix = 'wp'; 30 } 27 $xp_prefix = preg_replace('/wordpress/','wp',$mydirname); 31 28 32 29 $xoops_prefix = $db->prefix(); -
trunk/xpressme_integration_kit/include/onupdate.php
r534 r583 81 81 function xpress_put_siteurl($mydirname,$url){ 82 82 global $xoopsModule; 83 $wp_prefix = $mydirname; 84 if ($wp_prefix == 'wordpress'){ 85 $wp_prefix = 'wp'; 86 } 83 $wp_prefix = preg_replace('/wordpress/','wp',$mydirname); 87 84 $xoopsDB =& Database::getInstance(); 88 85 $db_xpress_option = $xoopsDB->prefix($wp_prefix . '_options'); … … 96 93 function xpress_put_home($mydirname,$url){ 97 94 global $xoopsModule; 98 $wp_prefix = $mydirname; 99 if ($wp_prefix == 'wordpress'){ 100 $wp_prefix = 'wp'; 101 } 95 $wp_prefix = preg_replace('/wordpress/','wp',$mydirname); 102 96 $xoopsDB =& Database::getInstance(); 103 97 $db_xpress_option = $xoopsDB->prefix($wp_prefix . '_options'); … … 111 105 function get_xpress_option($mydirname,$option_name){ 112 106 global $xoopsModule; 113 $wp_prefix = $mydirname; 114 if ($wp_prefix == 'wordpress'){ 115 $wp_prefix = 'wp'; 116 } 107 $wp_prefix = preg_replace('/wordpress/','wp',$mydirname); 117 108 $xoopsDB =& Database::getInstance(); 118 109 $option_table = $xoopsDB->prefix($wp_prefix . '_options'); … … 145 136 function get_db_version($mydirname){ 146 137 global $xoopsModule; 147 $wp_prefix = $mydirname; 148 if ($wp_prefix == 'wordpress'){ 149 $wp_prefix = 'wp'; 150 } 138 $wp_prefix = preg_replace('/wordpress/','wp',$mydirname); 151 139 $xoopsDB =& Database::getInstance(); 152 140 $db_xpress_option = $xoopsDB->prefix($wp_prefix . '_options'); … … 192 180 function xpress_table_make($module, $mydirname) 193 181 { 194 $xp_prefix = $mydirname;195 if ($xp_prefix == 'wordpress'){196 $xp_prefix = 'wp';197 }198 182 $db =& Database::getInstance() ; 199 183 $mid = $module->getVar('mid') ; 200 184 201 185 // XPressME orignal table update 202 $xp_prefix = $mydirname; 203 if ($xp_prefix == 'wordpress'){ 204 $xp_prefix = 'wp'; 205 } 186 $xp_prefix = preg_replace('/wordpress/','wp',$mydirname); 206 187 $msgs = array(); 207 188 … … 307 288 308 289 $xoopsDB =& Database::getInstance(); 309 if ($mydirname == 'wordpress'){ 310 $xpress_prefix= $xoopsDB->prefix('wp_'); 311 } else { 312 $xpress_prefix= $xoopsDB->prefix($mydirname . '_'); 313 } 290 $xpress_prefix = $xoopsDB->prefix(preg_replace('/wordpress/','wp',$mydirname) . '_'); 314 291 $db_enhanced = $xpress_prefix . $table_name; 315 292 -
trunk/xpressme_integration_kit/include/search.php
r496 r583 20 20 $myts =& MyTextSanitizer::getInstance(); 21 21 22 $xp_prefix = $mydirname; 23 if ($xp_prefix == 'wordpress'){ 24 $xp_prefix = 'wp'; 25 } 22 $xp_prefix = preg_replace('/wordpress/','wp',$mydirname); 26 23 if ($userid) { 27 24 $wp_uid = xoops_uid_to_wp_uid(intval($userid),$mydirname); -
trunk/xpressme_integration_kit/include/sitemap.plugin.php
r423 r583 30 30 $disp_sub =@$sitemap_configs["show_subcategoris"]; 31 31 32 $prefix = $mydirname; 33 if ($prefix == 'wordpress') $prefix ='wp'; 32 $prefix = preg_replace('/wordpress/','wp',$mydirname); 34 33 $prefix = $xoopsDB->prefix($prefix); 35 34 require_once (XOOPS_ROOT_PATH . '/modules/'.$mydirname . '/include/general_functions.php'); -
trunk/xpressme_integration_kit/include/xpress_block_render.php
r573 r583 84 84 if (is_null($wpdb)){ 85 85 $xoopsDB =& Database::getInstance(); 86 $wp_prefix = $mydirname; 87 if ($wp_prefix == 'wordpress') $wp_prefix = 'wp'; 86 $wp_prefix = preg_replace('/wordpress/','wp',$mydirname); 88 87 89 88 $module_tbl = $xoopsDB->prefix($wp_prefix).'_options';
Note: See TracChangeset
for help on using the changeset viewer.