Description
Implement [bw_users] shortcodeSimilar to bw_table, this displays information about a selected set of users
Usage
$string = oiku_users( $atts, $content, $tag );Parameters
- $atts
- ( array ) optional – shortcode parameters
- $content
- ( string ) optional – not expected
- $tag
- ( string ) optional –
Returns
string generated HTMLSource
File name: oik-user/shortcodes/oik-user.phpLines:
1 to 20 of 20
function oiku_users( $atts=null, $content=null, $tag=null ) { $fields = bw_array_get( $atts, "fields", "name,bio,email" ); $atts[ "fields" ] = "all_with_meta"; $users = get_users( $atts ); bw_trace2( $users, "users" ); $atts[ "fields" ] = $fields; if ( count( $users) ) { oik_require( "shortcodes/oik-table.php" ); stag( "table"); oiku_query_table_columns( $atts, "user" ); stag( "tbody" ); foreach ( $users as $user ) { oiku_display_user( $user, $atts ); } etag( "tbody" ); etag( "table" ); } return( bw_ret() ); }View on GitHub
Called by
Invoked by
Calls
1 to 7 of 7
- bw_array_get() – Return the array[index] or array->index (for an object) or a default value if not set
- bw_ret() – Use bw_ret() to return the contents of $bwecho, leaving the global value as NULL
- bw_trace2() – Trace $value to the trace log file if tracing is active
- etag() – Output an end tag
- oiku_display_user() – Display the fields for the user
- oiku_query_table_columns() – Determine the columns to be displayed in the table
- stag() – Output an HTML opening tag
