Changeset 13108 for trunk/src/bp-blogs/bp-blogs-functions.php
- Timestamp:
- 09/12/2021 08:43:39 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-blogs/bp-blogs-functions.php
r12779 r13108 45 45 46 46 // Parse query arguments. 47 $r = bp_parse_args( $args, array( 48 'type' => 'active', // 'active', 'alphabetical', 'newest', or 'random'. 49 'include_blog_ids' => false, // Array of blog IDs to include. 50 'user_id' => false, // Limit to blogs this user can post to. 51 'search_terms' => false, // Limit to blogs matching these search terms. 52 'per_page' => 20, // The number of results to return per page. 53 'page' => 1, // The page to return if limiting per page. 54 'update_meta_cache' => true // Whether to pre-fetch blogmeta. 55 ), 'blogs_get_blogs' ); 47 $r = bp_parse_args( 48 $args, 49 array( 50 'type' => 'active', // 'active', 'alphabetical', 'newest', or 'random'. 51 'include_blog_ids' => false, // Array of blog IDs to include. 52 'user_id' => false, // Limit to blogs this user can post to. 53 'search_terms' => false, // Limit to blogs matching these search terms. 54 'per_page' => 20, // The number of results to return per page. 55 'page' => 1, // The page to return if limiting per page. 56 'update_meta_cache' => true, // Whether to pre-fetch blogmeta. 57 ), 58 'blogs_get_blogs' 59 ); 56 60 57 61 // Get the blogs. … … 100 104 101 105 // Query for all sites in network. 102 $r = bp_parse_args( $args, array( 103 'offset' => (int) bp_get_option( '_bp_record_blogs_offset' ), 104 'limit' => 50, 105 'blog_ids' => array(), 106 'site_id' => $wpdb->siteid 107 ), 'record_existing_blogs' ); 106 $r = bp_parse_args( 107 $args, 108 array( 109 'offset' => (int) bp_get_option( '_bp_record_blogs_offset' ), 110 'limit' => 50, 111 'blog_ids' => array(), 112 'site_id' => $wpdb->siteid, 113 ), 114 'record_existing_blogs' 115 ); 108 116 109 117 // Truncate all BP blogs tables if starting fresh. … … 1532 1540 ); 1533 1541 1534 $submitted_vars = wp_parse_args( $_POST, $exprected_vars ); 1542 $submitted_vars = bp_parse_args( 1543 $_POST, 1544 $exprected_vars 1545 ); 1535 1546 1536 1547 return array_map( 'wp_unslash', array_intersect_key( $submitted_vars, $exprected_vars ) );
Note: See TracChangeset
for help on using the changeset viewer.