WordPress.org

Forums

World Cup Predictor
[resolved] Reset ranking for 2nd Phase (7 posts)

  1. chuntah
    Member
    Posted 1 year ago #

    Hi landoweb,

    I'm still using the version v1.8 and it's working fine. For the 2nd phase, i would like to reset the ranking of my users. I saw in another post, that you said adding the shortcode playoff=1 but it's not working for me. Any clue?
    Besides, what is the way to reset the ranking widget?
    Thanks for your help!

    jeffrey

    https://wordpress.org/plugins/world-cup-predictor/

  2. landoweb
    Member
    Plugin Author

    Posted 1 year ago #

    This feature is only available in version 1.9.2.

  3. chuntah
    Member
    Posted 1 year ago #

    Is there anyway i can have the samething in v1.8? Modification in php for example?

  4. landoweb
    Member
    Plugin Author

    Posted 1 year ago #

    You can edit the file world-cup-predictor.php, adding playoff on shotcode_atts and changing the call of user_ranking():

    if ($ranking) {
    			require_once(dirname(__FILE__).'/wcp-reports.class.php');
    			$r = new WorldCupReport();
    			$output =  $r->user_ranking($limit, $avatar, $highlight, $stage, $playoff);
    			return $output;
    		}

    And change the function user_ranking() on file wcp-reports.class.php, including the filter:

    if ($playoff) $stage_filter = "AND is_group = 0";

  5. chuntah
    Member
    Posted 1 year ago #

    Thank you Landoweb! I've been ableto add the feature manually.
    What about the ranking widget? Could you please advise?

  6. landoweb
    Member
    Plugin Author

    Posted 1 year ago #

    You need to modify the file wcp-widgets.class.php

  7. chuntah
    Member
    Posted 1 year ago #

    Ya. Found it too.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • World Cup Predictor
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic

Tags

No tags yet.