Support Forum

Advanced Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
coding-topic
Add column to member list
Avatar
LeoS
Member
Free Members
sp_UserOfflineSmall Offline
Apr 24, 2014 - 10:07 am

Is there a way to add/replace a column to the Member List? More in particular I would like to add the 'Location' data.

Avatar
Yellow Swordfish
Glinton, England
SP Master
sp_UserOfflineSmall Offline
Apr 24, 2014 - 12:31 pm

Well - the whole thing is driven by a template so adding and removing items is pretty straightforward although there is no display function for the location at the moment. But it could be done inline with a little simple html.

More importantly - Location is not a part of the data object that populates each members row. This can be overcome using a couple of WP style filters but I would warn you that because of the really rather nasty way that WordPress stores user profile data it would mean an extra SQL query for every row - i,e., per member displayed. So a little on the expensive side.

Does that sound worth tackling?

andy-signature.png
YELLOW
SWORDFISH
Avatar
LeoS
Member
Free Members
sp_UserOfflineSmall Offline
Apr 24, 2014 - 1:22 pm

No, it's not that important. But you must agree that the information displayed on the Member List at the moment is not very exciting and/or useful and hence rather pointless. 

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Apr 24, 2014 - 7:23 pm

why would we agree with that?

Avatar
LeoS
Member
Free Members
sp_UserOfflineSmall Offline
Apr 24, 2014 - 10:40 pm

Well, then don't wink

Avatar
Yellow Swordfish
Glinton, England
SP Master
sp_UserOfflineSmall Offline
Apr 25, 2014 - 6:30 am

Being serious for a moment it really depends what people may want to use the membership list for. We have all sorts from people who would like more to people who went less!

As I explained - the main issue is not what data to show but getting at that data, I was quite serious in my criticism of the way WordPress stores user profile data. They have made it impossible to perform simple and quick database queries to get at this data and every item of data you add adds complex database reads which slows things up when shown in a list. But it can be done.

andy-signature.png
YELLOW
SWORDFISH
Avatar
LeoS
Member
Free Members
sp_UserOfflineSmall Offline
Apr 25, 2014 - 7:27 am

On a private forum with a small amount of users, it would be nice to have the option to use the member listing as some kind of address book, with an export-to-csv function and such.

On the other hand, there are other WP plugins for this.

Avatar
Mr Papa
Simi Valley, CA
SP Master
Free Members
sp_UserOfflineSmall Offline
Apr 25, 2014 - 11:53 am

the template file for the members list can show whatever you like...  as a default, we had to choose something that exists within the forum since no way for us to have any idea what users might have or want there that might be unique per site...

have you looked at the spMembersView.php template file in the sp theme you are using?  you could replace the entire display (even the sp head and foot blocks) and put whatever you want there... if you have a wp plugin with a template tag for displaying the info (ie address book), you cold add it instead and display it...

the template files are very flexible and powerful for modification...

Forum Timezone: Europe/Stockholm
Most Users Ever Online: 1170
Currently Online:
Guest(s) 1
Currently Browsing this Page:
1 Guest(s)
Top Posters:
Mr Papa: 19448
Ike: 2086
Brandon: 864
kvr28: 804
jim: 650
FidoSysop: 577
Conrad_Farlow: 531
fiddlerman: 358
Stefano Prete: 325
Member Stats:
Guest Posters: 620
Members: 17365
Moderators: 0
Admins: 4
Forum Stats:
Groups: 7
Forums: 17
Topics: 10128
Posts: 79626