Support Forum
I'm not aware of potential oddities, but actually I need to filter display names everywhere.
About the user ID absence... maybe it can be retrieved with a custom query on wpdv object?
speaking about performances, what do you think it's better approach?
ps: how do I paste code correctly here?
if you tried that your performance hit would be noticeable. The approach we are taking is already a little expensive with all those usermeta database reads - but that would be made a lot worse.
So where else is left then?
Paste your code into the post. Select it with your mouse cursor taking care to ONLY select the code. When selected, click on the the Syntax Highlighter toolbar button (far right) and select the language.
YELLOW
SWORDFISH
|
Ok I'm lucky (and well-educated by your advices)
So in one move I've manages points 1, 2 and 3
with this:
add_filter('sph_topic_list_record', 'sph_addMetatoListLastPostObj'); function sph_addMetatoListLastPostObj($objData) { $cortesiaTitle = get_user_meta($objData->user_id, 'cortesia', True); $objData->display_name = $cortesiaTitle . ' '.$objData->display_name; return $objData; }
And I found out even the Members List:
add_filter('sph_members_list_records', 'sph_addMetatoMembersListObj'); function sph_addMetatoMembersListObj($objData) { $cortesiaTitle = get_user_meta($objData->user_id, 'cortesia', True); $objData->display_name = $cortesiaTitle . ' '.$objData->display_name; return $objData; }
I've just the Forum stats left now... I really can't find it!
Well, after a deeper look I do not think there's a way to change display names in stats as we did i previous snippets.
I cannot find any class or object with stats records.
the only way I'm able to do it is just
1) copy/paste entire fuctions (sp_OnlineStats, sp_TopPostersStats, sp_NewMembers, sp_AdminsList) in my sp theme functions.php
2) rename them (sp_OnlineStats2, sp_TopPostersStats2, sp_NewMembers2, sp_AdminsList2)
3) adding my meta in a procedural way when theese functions build the Display name
4) Use theese cloned functions in my theme spFoot.php
am I correct?
Sorry but it is going to have to be in the morning now. I have a plan to help you with an easy way to fix up the rest but need to run a few tests first. I will check this out in the morning.
Well a visit to Rome would be fun actually. We have been coming to Italy a couple of times each year recently but I have still not got to Rome. We are both (my wife and I) big fans of your country. I had a few days in Venice just a couple of weeks back in fact.
YELLOW
SWORDFISH
|
Ah, Roma! love it there! Have been maybe 10 or 12 times... All but one on business, but always spend extra time there... Last trip a couple years ago and got to take the whole family! great city!
Visit Cruise Talk Central and Mr Papa's World
1 Guest(s)