Changeset 3362
- Timestamp:
- 07/14/2011 01:38:56 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/plugin/bbp-includes/bbp-core-compatibility.php
r3348 r3362 29 29 * 30 30 * @global bbPress $bbp 31 * @param string $theme 31 * @param string $theme 32 32 * @uses current_theme_supports() 33 33 */ 34 34 function bbp_theme_compat_set_theme( $theme = array() ) { 35 35 36 36 // Check if current theme supports bbPress 37 37 if ( empty( $bbp->theme_compat->theme ) && !current_theme_supports( 'bbpress' ) ) { … … 40 40 41 41 if ( empty( $theme ) ) { 42 $theme = array( 42 $theme = array( 43 43 'dir' => $bbp->themes_dir . '/bbp-twentyten', 44 44 'url' => $bbp->themes_url . '/bbp-twentyten' … … 201 201 function bbp_set_theme_compat_templates( $templates = array() ) { 202 202 global $bbp; 203 203 204 204 $bbp->theme_compat->templates = $templates; 205 205 206 206 return $bbp->theme_compat->templates; 207 207 } … … 219 219 function bbp_set_theme_compat_template( $template = '' ) { 220 220 global $bbp; 221 221 222 222 $bbp->theme_compat->template = $template; 223 223 224 224 return $bbp->theme_compat->template; 225 225 } … … 290 290 $wp_query->is_archive = false; 291 291 $wp_query->is_tax = false; 292 292 293 293 // If we are resetting a post, we are in theme compat 294 294 bbp_set_theme_compat_active(); … … 600 600 $templates = apply_filters( 'bbp_get_reply_edit_template', $templates ); 601 601 $templates = bbp_set_theme_compat_templates( $templates ); 602 602 603 603 $template = locate_template( $templates, false, false ); 604 604 $template = bbp_set_theme_compat_template( $template ); … … 974 974 // Forum archive 975 975 } elseif ( bbp_is_forum_archive() ) { 976 976 977 977 // Page exists where this archive should be 978 978 if ( $page = bbp_get_page_by_path( $bbp->root_slug ) ) { … … 1219 1219 */ 1220 1220 function bbp_get_page_by_path( $path = '' ) { 1221 1221 1222 1222 // Default to false 1223 1223 $retval = false; … … 1504 1504 // We save post revisions on our own 1505 1505 remove_action( 'pre_post_update', 'wp_save_post_revision' ); 1506 1507 // Topic tag page 1508 } elseif ( bbp_is_topic_tag() ) { 1509 $posts_query->query_vars['post_type'] = bbp_get_topic_post_type(); 1506 1510 } 1507 1511
Note: See TracChangeset
for help on using the changeset viewer.