Changeset 757 for branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/custom_functions.php
- Timestamp:
- May 23, 2011, 3:03:57 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/Ver3.0/xpressme_integration_kit/wp-content/plugins/xpressme/include/custom_functions.php
r688 r757 40 40 41 41 function xpress_is_multiblog() { 42 global $xoops_config;43 44 42 if (function_exists('is_multisite') && is_multisite()) return true; 45 43 return false; … … 56 54 57 55 function xpress_is_wp_version($operator='==',$comp_version){ 58 global $ xoops_config;59 return version_compare($ xoops_config->wp_version, $comp_version, $operator);56 global $modInfo; 57 return version_compare($modInfo->get_wp_version(), $comp_version, $operator); 60 58 } 61 59 … … 184 182 function xpress_credit($args ='') 185 183 { 186 global $wp_version , $xoops_config; 187 if ($xoops_config->is_wpmu) { 188 global $wpmu_version; 189 } 184 global $wp_version , $modInfo; 190 185 191 186 $defaults = array( … … 197 192 extract( $r ); 198 193 199 $xpress_version = $ xoops_config->module_version;200 $xpress_codename = $ xoops_config->module_codename;194 $xpress_version = $modInfo->get_module_version(); 195 $xpress_codename = $modInfo->get_module_codename(); 201 196 if ($no_link){ 202 if ($xoops_config->is_wpmu) {203 $output = 'XPressMU Ver.' . sprintf('%.2f %s',$xpress_version,$xpress_codename);204 $output .= '(included WordPress MU ' . $wpmu_version. ')';197 $output = 'XPressME Ver.' . sprintf('%.2f %s',$xpress_version,$xpress_codename); 198 if (strstr($wp_version,'ME')){ 199 $output .= '(included WordPress ' . $wp_version . ')'; 205 200 } else { 206 $output = 'XPressME Ver.' . sprintf('%.2f %s',$xpress_version,$xpress_codename); 207 if (strstr($wp_version,'ME')){ 208 $output .= '(included WordPress ' . $wp_version . ')'; 209 } else { 210 $output .= '(included WordPress ' . $wp_version . ')'; 211 } 212 } 213 } else { 214 if ($xoops_config->is_wpmu) { 215 $output = '<a href="http://ja.xpressme.info"'. " target='_blank'" . '>XPressMU Ver.' . sprintf('%.2f %s',$xpress_version,$xpress_codename) .'</a>'; 216 $output .= '(included <a href="http://mu.wordpress.org/" title="Powered by WordPress"'." target='_blank'". '>WordPress MU ' . $wpmu_version . '</a>)'; 201 $output .= '(included WordPress ' . $wp_version . ')'; 202 } 203 } else { 204 $output = '<a href="http://ja.xpressme.info"'. " target='_blank'" . '>XPressME Ver.' . sprintf('%.2f %s',$xpress_version,$xpress_codename) .'</a>'; 205 if (strstr($wp_version,'ME')){ 206 $output .= '(included <a href="http://wpme.sourceforge.jp/" title="Powered by WordPress"'." target='_blank'". '>WordPress ' . $wp_version . '</a>)'; 217 207 } else { 218 $output = '<a href="http://ja.xpressme.info"'. " target='_blank'" . '>XPressME Ver.' . sprintf('%.2f %s',$xpress_version,$xpress_codename) .'</a>'; 219 if (strstr($wp_version,'ME')){ 220 $output .= '(included <a href="http://wpme.sourceforge.jp/" title="Powered by WordPress"'." target='_blank'". '>WordPress ' . $wp_version . '</a>)'; 221 } else { 222 $output .= '(included <a href="http://wordpress.org/" title="Powered by WordPress"'." target='_blank'". '>WordPress ' . $wp_version . '</a>)'; 223 } 208 $output .= '(included <a href="http://wordpress.org/" title="Powered by WordPress"'." target='_blank'". '>WordPress ' . $wp_version . '</a>)'; 224 209 } 225 210 } … … 664 649 function xpress_post_new_link($args ='') 665 650 { 666 global $ xoops_config;651 global $modInfo; 667 652 668 653 $defaults = array( … … 846 831 847 832 function xpress_get_calendar($args = '') { 848 global $wpdb, $m, $monthnum, $year, $wp_locale, $posts , $ xoops_config;833 global $wpdb, $m, $monthnum, $year, $wp_locale, $posts , $modInfo; 849 834 850 835 $defaults = array( … … 1035 1020 1036 1021 function xpress_create_new_blog_link($args ='' ) { 1037 global $ xoops_config;1022 global $modInfo; 1038 1023 1039 1024 global $current_user; … … 1058 1043 1059 1044 function xpress_create_new_blog() { 1060 global $ xoops_config;1045 global $modInfo; 1061 1046 global $current_user; 1062 1047 $ret = array(); … … 1070 1055 case 'all': 1071 1056 case 'blog': 1072 $ret['url'] = $ xoops_config->module_url. '/wp-signup.php';1057 $ret['url'] = $modInfo->get_module_url() . '/wp-signup.php'; 1073 1058 $ret['menu_url'] = 'wp-signup.php'; 1074 1059 $ret['title'] = __('Create New Blog','xpressme'); … … 1083 1068 } 1084 1069 function xpress_primary_blog_link() { 1085 global $ xoops_config;1070 global $modInfo; 1086 1071 global $current_user; 1087 1072 global $blog_id;
Note: See TracChangeset
for help on using the changeset viewer.