[ Index ] |
PHP Cross Reference of BuddyPress |
[Summary view] [Print] [Text view]
1 <?php 2 /** 3 * Members: Random member action handler 4 * 5 * @package BuddyPress 6 * @subpackage MembersActions 7 * @since 3.0.0 8 */ 9 10 /** 11 * Redirect to a random member page when visiting a ?random-member URL. 12 * 13 * @since 1.0.0 14 */ 15 function bp_core_get_random_member() { 16 if ( ! isset( $_GET['random-member'] ) ) 17 return; 18 19 $user = bp_core_get_users( array( 'type' => 'random', 'per_page' => 1 ) ); 20 bp_core_redirect( bp_core_get_user_domain( $user['users'][0]->id ) ); 21 } 22 add_action( 'bp_actions', 'bp_core_get_random_member' );
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Thu Nov 21 01:00:57 2024 | Cross-referenced by PHPXref 0.7.1 |