68% football-odds

Code Review | Football Odds

WordPress plugin Football Odds scored68%from 54 tests.

About plugin

  • Plugin page: football-odds
  • Plugin version: 1.9
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.9
  • WordPress version: 6.3.1
  • First release: Dec 14, 2015
  • Latest release: Mar 29, 2018
  • Number of updates: 43
  • Update frequency: every 19.4 days
  • Top authors: Patrick_Al (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /3,689 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼11.06ms] Passed 4 tests

Server-side resources used by Football Odds
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0148.79 ▲8.02
Dashboard /wp-admin3.32 ▲0.0147.77 ▼6.99
Posts /wp-admin/edit.php3.37 ▲0.0143.61 ▼9.12
Add New Post /wp-admin/post-new.php5.92 ▲0.0384.52 ▼28.51
Media Library /wp-admin/upload.php3.24 ▲0.0135.91 ▲0.40
Football Odds /wp-admin/admin.php?page=football-odds/footballodds.php3.35224.08
Click Report /wp-admin/admin.php?page=football-odds/footballodds.php/reports3.26175.99
Create ShortCode /wp-admin/admin.php?page=football-odds/footballodds.php/shortcode3.2932.56
Tables Style /wp-admin/admin.php?page=football-odds/footballodds.php/customization3.2836.58

Server storage [IO: ▲0.21MB] [DB: ▲0.07MB] Passed 3 tests

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 22 new files
Database: 2 new tables, 6 new options
New tables
wp_fodds_customization
wp_fodds_settings
New WordPress options
db_upgraded
can_compress_scripts
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

A check of browser resources used by Football Odds
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,828 ▲6714.15 ▼0.201.82 ▲0.2746.32 ▲8.11
Dashboard /wp-admin2,226 ▲545.66 ▼0.0699.19 ▼5.4241.66 ▼4.06
Posts /wp-admin/edit.php2,140 ▲401.99 ▼0.0338.90 ▼2.4135.84 ▲3.15
Add New Post /wp-admin/post-new.php1,556 ▲3023.08 ▼0.62675.57 ▼46.6048.38 ▼11.77
Media Library /wp-admin/upload.php1,440 ▲404.23 ▲0.01100.96 ▼6.3444.64 ▼1.38
Football Odds /wp-admin/admin.php?page=football-odds/footballodds.php1,2012.0125.3035.64
Click Report /wp-admin/admin.php?page=football-odds/footballodds.php/reports1,0171.9923.4429.02
Create ShortCode /wp-admin/admin.php?page=football-odds/footballodds.php/shortcode1,9782.1523.4746.97
Tables Style /wp-admin/admin.php?page=football-odds/footballodds.php/customization1,0551.8527.8425.65

Uninstaller [IO: ▲0.00MB] [DB: ▲0.07MB] 50% from 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • The plugin did not uninstall successfully, leaving 2 tables in the database
    • wp_fodds_customization
    • wp_fodds_settings
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
These errors were triggered by the plugin
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Warning in wp-content/plugins/football-odds/fodds_reports.php+8
    simplexml_load_file(): php_network_getaddresses: getaddrinfo failed: Name or service not known
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php
    • > Warning in wp-content/plugins/football-odds/fodds_admin.php+93
    simplexml_load_file(http://base.oddslords.com/check.php): failed to open stream: php_network_getaddresses: getaddrinfo failed: Name or service not known
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php
    • > Warning in wp-content/plugins/football-odds/fodds_admin.php+93
    simplexml_load_file(): I/O warning : failed to load external entity "http://base.oddslords.com/check.php"
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php
    • > Warning in wp-content/plugins/football-odds/functions/functions.php+31
    file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php
    • > Warning in wp-content/plugins/football-odds/functions/functions.php+31
    file_get_contents(http://base.oddslords.com/check.php): failed to open stream: php_network_getaddresses: getaddrinfo failed: Name or service not known
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php
    • > Notice in wp-content/plugins/football-odds/fodds_admin.php+134
    Trying to access array offset on value of type bool
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Warning in wp-content/plugins/football-odds/fodds_reports.php+8
    simplexml_load_file(http://base.oddslords.com//g2/reports.php?site=http%3A%2F%2Fwp.com): failed to open stream: php_network_getaddresses: getaddrinfo failed: Name or service not known
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Warning in wp-content/plugins/football-odds/fodds_reports.php+8
    simplexml_load_file(): I/O warning : failed to load external entity "http://base.oddslords.com//g2/reports.php?site=http%3A%2F%2Fwp.com"
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+24
    Trying to get property 'sip' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+30
    Trying to get property 'r365' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+31
    Trying to get property 'r365u' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+35
    Trying to get property 'rb10' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+36
    Trying to get property 'rb10u' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+40
    Trying to get property 'rbwin' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+41
    Trying to get property 'rbwinu' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+45
    Trying to get property 'runibet' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+46
    Trying to get property 'runibetu' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+52
    Trying to get property 'rwh' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+53
    Trying to get property 'rwhu' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+59
    Trying to get property 'r888' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+60
    Trying to get property 'r888u' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+66
    Trying to get property 'rbol' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+67
    Trying to get property 'rbolu' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+73
    Trying to get property 'rlad' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+74
    Trying to get property 'rladu' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+81
    Trying to get property 'rsbo' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+82
    Trying to get property 'rsbou' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+88
    Trying to get property 'r1xb' of non-object
    • > GET request to /wp-admin/admin.php?page=football-odds/footballodds.php/reports
    • > Notice in wp-content/plugins/football-odds/fodds_reports.php+89
    Trying to get property 'r1xbu' of non-object

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following
  • 5× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/football-odds/footballodds.php
    • > /wp-content/plugins/football-odds/fodds_shortcoder.php
    • > /wp-content/plugins/football-odds/fodds_admin.php
    • > /wp-content/plugins/football-odds/fodds_cusomization.php
    • > /wp-content/plugins/football-odds/fodds_reports.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
5 plugin tags: free, odds, football, comparison, soccer

football-odds/footballodds.php 92% from 13 tests

"Football Odds" version 1.9's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please take the time to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("football-odds.php" instead of "footballodds.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected2,097 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP7128341,231
JavaScript113938834
CSS10032

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.15
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions30
▷ Named functions30100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
9 PNG files occupy 0.04MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
js/hs.png2.62KB7.54KB0.00%
img/redstar.png0.41KB0.37KB▼ 9.11%
img/glass2.png0.14KB0.09KB▼ 32.17%
js/hv.png2.80KB7.32KB0.00%
img/logo_100x100.png18.56KB6.09KB▼ 67.18%