• Resolved pglock

    (@pglock)


    When a user has already used a joker (and the match has been played) is there some way of informing them or hiding the Joker icon so that they can’t attempt to set another joker before all matches are completed.

    The page I need help with: [log in to see the link]

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

    (@antoineh)

    I don’t know if there is a simple way of hiding the joker icon. That’s something I would also have to do research on. My first thought would be to use the hook for the prediction form template. Use it to add some logic that enables or disables the output of the joker.

    But the plugin does already contain logic to prevent the setting of another joker if one was already set and activated. The plugin won’t allow another joker. So, not sure if extending the plugin is really necessary.

    Thread Starter pglock

    (@pglock)

    The issue as I see it is when I use the extension football-pool-only-open-matches so that it’s not obvious when the joker has already been played.

    Plugin Author AntoineH

    (@antoineh)

    Ah, I see. I will see if I can figure something out.

    Plugin Author AntoineH

    (@antoineh)

    Try this extra plugin: Football Pool Hide Joker. This will hide the icon when it cannot be set anymore.

    It also has a publicly accessible method to determine if a user has used his/her joker. This can be used in other plugins if you wish to also display a message somewhere.

    public static function user_has_used_joker( $user_id )

    Thread Starter pglock

    (@pglock)

    Works perfectly. Thank you

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Joker, showing when already used’ is closed to new replies.