Changeset 5729 for trunk/bp-core/bp-core-functions.php
- Timestamp:
- 02/11/2012 09:32:04 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-core/bp-core-functions.php
r5724 r5729 126 126 // from the current blog 127 127 $posts_table_name = bp_is_multiblog_mode() ? $wpdb->posts : $wpdb->get_blog_prefix( bp_get_root_blog_id() ) . 'posts'; 128 $page_ids_sql = implode( ',', (array) $page_ids );128 $page_ids_sql = implode( ',', (array) $page_ids ); 129 129 $page_names = $wpdb->get_results( $wpdb->prepare( "SELECT ID, post_name, post_parent, post_title FROM {$posts_table_name} WHERE ID IN ({$page_ids_sql}) AND post_status = 'publish' " ) ); 130 130 … … 345 345 $time_chunks = explode( ':', str_replace( ' ', ':', $older_date ) ); 346 346 $date_chunks = explode( '-', str_replace( ' ', '-', $older_date ) ); 347 $older_date = gmmktime( (int) $time_chunks[1], (int)$time_chunks[2], (int)$time_chunks[3], (int)$date_chunks[1], (int)$date_chunks[2], (int)$date_chunks[0] );347 $older_date = gmmktime( (int) $time_chunks[1], (int) $time_chunks[2], (int) $time_chunks[3], (int) $date_chunks[1], (int) $date_chunks[2], (int) $date_chunks[0] ); 348 348 } 349 349 … … 688 688 689 689 // Check if the slug is registered in the $bp->pages global 690 foreach ( (array) $bp->pages as $key => $page ) {690 foreach ( (array) $bp->pages as $key => $page ) { 691 691 if ( $key == $slug || $page->slug == $slug ) 692 692 $match = true; … … 710 710 $new_page_ids = array(); 711 711 712 foreach ( (array) $bp->add_root as $slug )712 foreach ( (array) $bp->add_root as $slug ) 713 713 $new_page_ids[$slug] = wp_insert_post( array( 'comment_status' => 'closed', 'ping_status' => 'closed', 'post_title' => ucwords( $slug ), 'post_status' => 'publish', 'post_type' => 'page' ) ); 714 714
Note: See TracChangeset
for help on using the changeset viewer.