Support Forum
I was wondering if there is a way to display the amount of CubePoints a user has in their forum profile? I have disabled the wp-admin access so now there isn't a convenient way for users to see how many points they have. Perhaps a new tab on the profile view after the Buddies / Adversaries?
Also, is there a way that I can display a users CubePoints in the User Information on forum posts? Maybe under forum rank? Thanx in advance for your help with this!
well, ya know... not easily... looks like when the plugin was written, with a single template function, it made an assumption of displaying only in the topic list loop... at least with some level of styling... I will open a ticket to add a more general template tag...
in the meantime, you can modify the popup template file you want it to show in (page or popup) in your sp theme...
and you can display the users points with:
echo get_option('cp_prefix').cp_getPoints($userid).get_option('cp_suffix');
where you will want to replace $userid with the id of the user you are viewing... this will likely be: $spProfileUser->ID
you will need to add any text or styling around as that will just output a value...
Visit Cruise Talk Central and Mr Papa's World
Just added cube points to my site and forum, and was looking for the same
And maybe not just in the profile page, but also somewhere by the user's screen name and avatar in the forum and site.
It's an awesome plugin, but defeats the purpose if the user isn't made aware of the fact that they're earning them
you can do it now as per my directions in post #2... you just have to add to your profile or wherever you want... keep in mind when we add the additional template tag as I said, you will still have to add it to your sp theme - just be easier to style...
Visit Cruise Talk Central and Mr Papa's World
Ahh, i gotcha. Thanks, Mr. Papa.
It's been awhile since I edited the simplepress forum templates - I'll have to dig around to find the best placements now.
Will that same string of code work in the profile page, the actual forum post (by the avatar area) and by their names on blog post comments...?
with 5.0, you will want to occasionally play with the sp theme if you want to customize... easier than before editing core!
be sure to see this article: http://codex.simple-press.com/.....g-a-theme/
before making any changes to our core sp themes...
if you want to put it by the avatar in a topic, that is the one spot our plugin was explicitly designed for... what I want to add is a more generic template function for other areas...
again, what you want is to use the template tag in the plugin... just add:
sp_PostIndexCubePoints();
in your spTopicView.php template file of the sp theme you are using... add it where you want it to display...
Visit Cruise Talk Central and Mr Papa's World
Hi Mr. Papa,
I started messing around with the bits of code you referenced above. It works great, listed on the topic with the user's avatar. However, when trying to add to the profile, the count is always "0", even when I know that particular user has points, according to the admin. Am I missing something else...?
you would need to post the exact code you used please... and where you put it...
Visit Cruise Talk Central and Mr Papa's World
1 Guest(s)