• Resolved METRO design

    (@metro-design)


    Hi,
    I’m using your plugin and it is great one. I have little let’s say request.
    Is there the shortcode that I can use to show score of any user’s/player’s profile. I mean his own points. I use Buddypress on my site and I’d like to show, on each single player’s profile, points that player has achieved during the game as score. I don’t see way right now I can display it on profiles, except on own profile (logged in user profile).

    Genneraly, I need shortcode like: [fp-score user: (user that I’m visiting his profile)], so I and every other player can see his points he achieved in any moment…
    If you uderstand what I’m asking for or if I’m missing that shortcode or there is some other way, please, notify me.

    P.S.: Sorry for my english it’s not perfect…

    Thank you!

    https://www.ads-software.com/plugins/football-pool/

Viewing 9 replies - 1 through 9 (of 9 total)
  • Plugin Author AntoineH

    (@antoineh)

    Hi, don’t worry about your English. Your question is perfectly clear ??

    There is a [fp-user-score] shortcode that should do the trick.
    See https://www.ads-software.com/plugins/football-pool/other_notes/ for all the other shortcodes and/or the help page in the admin for details about the shortcodes.

    Thread Starter METRO design

    (@metro-design)

    I’ve tried that shortcode, but it still is showing the score that I have scored during the game, even I’m on other player’s profile. Is there anything that can be modified or developed to make it do the trick?

    [fp-user-score user=1 text=”no score”]
    This one looks promising, but if only this “1” could be replaced by universal player id (like ID reader so it imediately knows which player is selected and shows his points), something like $user_ID so it automaticaly do the job…

    Thread Starter METRO design

    (@metro-design)

    Is it possible?

    Plugin Author AntoineH

    (@antoineh)

    Sorry, was away for the weekend.

    WordPress has a do_shortcode function that allows you to ‘fire’ shortcodes via PHP code. So, if you can determine the user ID of the score you would like to show, you can do something like this:

    do_shortcode( "[fp-user-score user={$user_ID} text='no score']" )

    If you can’t change the PHP code of the profile page, you can consider using a plugin that allows you to add custom PHP code to your content.

    Thread Starter METRO design

    (@metro-design)

    I’m not sure what I’m suposed to do with PHP of profile?
    Just paste this code?

    Plugin Author AntoineH

    (@antoineh)

    No, just pasting this code won’t work. You’ll have to figure out what the user ID is for the user in the profile page and then use that variable in the code example.
    If you want this to work you’ll need some PHP programming experience.

    Thread Starter METRO design

    (@metro-design)

    Ok, I’ll try something. Thank you ??

    Thread Starter METRO design

    (@metro-design)

    By the way… I think that could be great extension for your plugin.
    When you decide to do “big update” to plugin than probably you should reconsider this thing. Buddypress is like foundament of any good site.

    Plugin Author AntoineH

    (@antoineh)

    At the moment I have no plans for a big update and/or integration with other plugins.

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Player profile show score’ is closed to new replies.