Changeset 589
- Timestamp:
- Apr 27, 2010, 1:40:05 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/xpressme_integration_kit/xoops_version.php
r586 r589 48 48 return $role_level; 49 49 } 50 } 51 } 52 if (!function_exists('is_show_multi_blog_block')){ 53 function is_show_multi_blog_block($mydirname = ''){ 54 if(empty($mydirname)) return false; 55 // Before loading xpressme. 56 // The multi blog is judged by the presence of the blogs table. 57 global $xoopsDB; 58 $wp_prefix = preg_replace('/wordpress/','wp',$mydirname); 59 $wp_blogs_tbl = $xoopsDB->prefix($wp_prefix) . '_blogs'; 60 $sql = "SELECT * FROM " . $wp_blogs_tbl; 61 $result = $xoopsDB->query($sql, 0, 0); 62 if ($xoopsDB->getRowsNum($result)) return true; 63 return false; 50 64 } 51 65 } … … 353 367 'func_num' => $b_no, 354 368 ); 355 if (wp_version_compare($wp_version, '>=','3.0-alpha') ){369 if (wp_version_compare($wp_version, '>=','3.0-alpha') && is_show_multi_blog_block($mydirname)){ 356 370 $b_no++; 357 371 $modversion['blocks'][$b_no] = array(
Note: See TracChangeset
for help on using the changeset viewer.