84% embed-chessboard

Code Review | Embed Chessboard

WordPress plugin Embed Chessboard scored84%from 54 tests.

About plugin

  • Plugin page: embed-chessboard
  • Plugin version: 3.06.00
  • PHP version: 7.4.16
  • WordPress compatibility: 2.9-6.3
  • WordPress version: 6.3.1
  • First release: Jan 29, 2010
  • Latest release: Jul 21, 2023
  • Number of updates: 613
  • Update frequency: every 8.0 days
  • Top authors: pgn4web (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

700+ active /39,948 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

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

An overview of server-side resources used by Embed Chessboard
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0137.17 ▼6.84
Dashboard /wp-admin3.32 ▲0.0245.46 ▼5.25
Posts /wp-admin/edit.php3.37 ▲0.0249.57 ▲1.83
Add New Post /wp-admin/post-new.php5.90 ▲0.0286.15 ▼15.34
Media Library /wp-admin/upload.php3.24 ▲0.0138.75 ▲3.87
Embed Chessboard /wp-admin/options-general.php?page=embed-chessboard/embedchessboard.php3.2135.22

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 67 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_theysaidso_widget
db_upgraded
widget_recent-posts
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Embed Chessboard
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,818 ▲5714.27 ▲0.121.87 ▲0.0944.23 ▼2.36
Dashboard /wp-admin2,199 ▲285.54 ▼0.0985.07 ▼13.4737.88 ▼5.55
Posts /wp-admin/edit.php2,101 ▼21.94 ▼0.0032.68 ▼6.3735.72 ▲0.25
Add New Post /wp-admin/post-new.php1,538 ▲1218.60 ▼4.91604.66 ▼42.4472.47 ▲21.69
Media Library /wp-admin/upload.php1,398 ▼24.25 ▼0.0199.53 ▲3.1641.27 ▼3.53
Embed Chessboard /wp-admin/options-general.php?page=embed-chessboard/embedchessboard.php1,1881.9127.2342.39

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

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

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/embed-chessboard/embedchessboard.php:332

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
There were no browser issues found

Optimizations

Plugin configuration 93% 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
4 plugin tags: chessboard, pgn4web, pgn, chess

embed-chessboard/embedchessboard.php 85% from 13 tests

The main PHP script in "Embed Chessboard" version 3.06.00 is automatically included on every request by WordPress
You should first fix the following items:
  • Description: The description should be shorter than 140 characters (currently 575 characters long)
  • Main file name: Name the main plugin file the same as the plugin slug ("embed-chessboard.php" instead of "embedchessboard.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 detected11,303 lines of code in 19 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript77772035,098
SVG4003,951
HTML3291271,594
PHP287187638
CSS373922

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.16
Average class complexity48.00
▷ Minimum class complexity48.00
▷ Maximum class complexity48.00
Average method complexity24.50
▷ Minimum method complexity2.00
▷ Maximum method complexity47.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods2
▷ Static methods00.00%
▷ Public methods2100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions8
▷ Named functions787.50%
▷ Anonymous functions112.50%
Constants0
▷ Global constants00.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
16 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
pgn4web/images/uscf/20/bk.png1.42KB0.92KB▼ 35.71%
pgn4web/images/uscf/20/wb.png1.38KB0.99KB▼ 28.60%
pgn4web/libs/jscolor/hs.png2.62KB7.54KB0.00%
pgn4web/images/uscf/20/bb.png1.24KB0.84KB▼ 31.73%
pgn4web/images/uscf/20/wr.png1.22KB0.73KB▼ 39.90%