lebo69
Forum Replies Created
-
Forum: Plugins
In reply to: [Football Pool] Cannot Add matcheschecked off keep data and deactivated and reactivated. now it works.
Thank you for your help.
Forum: Plugins
In reply to: [Football Pool] Cannot Add matchesyes, there are plenty of records, however, i could not find any pointing to football pool.
Forum: Plugins
In reply to: [Football Pool] Cannot Add matchesIm using godaddy managed hosting and there is a flush cache option.
Already flushed it and didnt fix the issue. I do not use any other securiity plguins.
Forum: Plugins
In reply to: [Football Pool] Cannot Add matchesThank you for your quick reply. I enabled debugging but i am not getting an error after i create a match. I get the response “Value Updated” but the new match does not show. I have 77 previously created matches and after adding a new one, it stays at 77.
Is there anything else i can check?
Forum: Plugins
In reply to: [Football Pool] Extension not workingActually, most of the extensions are giving the same error. Please let us know how to resolve this. Some of the extensions are needed.
Thank you in advance
Forum: Plugins
In reply to: [Football Pool] Highcharts not displayingThat worked. Thanks.
Forum: Plugins
In reply to: [Football Pool] Highcharts not displayingOk so i guess it was working all along. However, i still dont see them on my desktop using Chrome. After seeing your reply, I tested on Safari desktop browser and i do see them.
Any ideas why it wont show on Chrome desktop browser?
Forum: Plugins
In reply to: [Football Pool] Error on Statistics PageWorked great. Thanks.
Forum: Plugins
In reply to: [Football Pool] Error on Statistics PageHi Antoine,
Here is the hide-zero-predictions.php file i have installed. I would appreciate your help when you can. Thanks.
<?php
/**
* Plugin Name: Football Pool Match Predictions Extension
* Description: Order match predictions by score and don’t show users without predictions.
* Version: 1.0
* Author: Antoine Hurkmans
* Author URI: mailto:[email protected]
* License: MIT
*/// Save this plugin in the wp-content/plugins folder and activate it //
class FootballPoolExtensionMatchPredictions {
public static function init_extension() {
if ( ! is_admin() ) {
add_filter( ‘footballpool_statistics_matchpredictions’, array( __CLASS__, ‘change_matchpredictions’ ), null, 2 );
}
}public static function change_matchpredictions( $predictions, $match_info ) {
// add score
array_walk( $predictions, array( __CLASS__, ‘add_score’ ), $match_info );
// remove users without predictions
$predictions = array_filter( $predictions, array( __CLASS__, ‘remove_inactive_users’ ) );
// sort by score
usort( $predictions, array( __CLASS__, ‘sort_table’ ) );return $predictions;
}public static function add_score( &$prediction, $key, $match_info ) {
$pool = new Football_Pool_Pool;
$prediction[‘score’] = $pool->calc_score(
$match_info[‘home_score’],
$match_info[‘away_score’],
$prediction[‘home_score’],
$prediction[‘away_score’],
$prediction[‘has_joker’]
);
}public static function remove_inactive_users( $prediction ) {
return ! is_null( $prediction[‘home_score’] ) && ! is_null( $prediction[‘away_score’] );
}public static function sort_table( $a, $b ) {
if ( $a[‘score’] == $b[‘score’] ) return 0;
return ( $a[‘score’] < $b[‘score’] ) ? 1 : -1;
}
}add_filter( ‘plugins_loaded’, array( ‘FootballPoolExtensionMatchPredictions’, ‘init_extension’ ) );
Forum: Plugins
In reply to: [Football Pool] Error on Statistics PageThanks Antoine, but I am not a PHP programmer and do not understand exactly what to do. Could you please let me know what to insert or change on the plugin file?
Thanks in advance.
Forum: Plugins
In reply to: [Football Pool] Error on Statistics PageThanks Antoine.
When you have the code or updated extension please share so i can fix this.
Thank you.
Forum: Plugins
In reply to: [Football Pool] Plugin adds 2 full seconds to average page load time!The new update actually sped up my load times. I have 2000 users and before the plugin, it took at least 3 to 5 seconds to load the rankings.
Working much better now. Thanks.
Forum: Plugins
In reply to: [Football Pool] PaginationWorked . Thank you.
Forum: Plugins
In reply to: [Football Pool] Ranking Widget problem after updating 2.5.2Hi Antoine,
How can this be fixed on 2.5.2?
Forum: Plugins
In reply to: [Football Pool] score calculationHi Antoine,
Do you have the new version of the calculation available? I have a large user base (2000+) and when i try to update, i always get an error.
Please let me know what tips you can give me to avoid this and if you have a new version available.
Thank you