Conversion to underscore.js messing up member directory pages
-
So we used to iterate through members in the member directory with a PHP foreach, like so:
<?php $i = 0; foreach( um_members(‘users_per_page’) as $member) { $i++; um_fetch_user( $member ); ?>
This no longer works in 2.1.2 as members-grid.php now uses underscore to iterate like so:
<# if ( data.length > 0 ) { #>
<# _.each( data, function( user, key, list ) { #>The issue here is that I cannot use um_user to fetch custom fields from user profiles – in this case, I only want to show a user’s first name – like we used to, and there’s no documentation as to how to do so in the new underscore loop. Kind of annoying!
The page I need help with: [log in to see the link]
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Conversion to underscore.js messing up member directory pages’ is closed to new replies.