84% sitelinks-search-box

Code Review | Sitelinks Search Box

WordPress plugin Sitelinks Search Box scored84%from 54 tests.

About plugin

  • Plugin page: sitelinks-search-box
  • Plugin version: 1.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-6.3
  • WordPress version: 6.3.1
  • First release: Sep 10, 2014
  • Latest release: Sep 23, 2023
  • Number of updates: 51
  • Update frequency: every 64.7 days
  • Top authors: apasionados (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

3,000+ active /41,260 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

Server metrics [RAM: ▼0.00MB] [CPU: ▼4.88ms] Passed 4 tests

Analyzing server-side resources used by Sitelinks Search Box
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0139.11 ▲0.64
Dashboard /wp-admin3.31 ▼0.0342.47 ▼17.65
Posts /wp-admin/edit.php3.36 ▲0.0144.78 ▼1.06
Add New Post /wp-admin/post-new.php5.89 ▲0.0188.59 ▼1.46
Media Library /wp-admin/upload.php3.24 ▲0.0134.64 ▲0.65

Server storage [IO: ▲0.03MB] [DB: ▲0.00MB] Passed 3 tests

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
db_upgraded

Browser metrics Passed 4 tests

Sitelinks Search Box: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,828 ▲8213.21 ▼1.241.99 ▲0.2644.40 ▲5.26
Dashboard /wp-admin2,200 ▲115.80 ▼0.10103.41 ▼8.4835.90 ▼8.03
Posts /wp-admin/edit.php2,089 ▲32.14 ▲0.1436.72 ▲0.3632.40 ▼2.76
Add New Post /wp-admin/post-new.php1,534 ▲623.08 ▼0.60639.15 ▼35.7063.71 ▲10.67
Media Library /wp-admin/upload.php1,388 ▲64.19 ▲0.0397.03 ▼5.7141.31 ▼2.63

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following items
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/sitelinks-search-box/sitelinks-search-box.php:29

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
7 plugin tags: json-ld, search engines, google sitelinks, google, google sitelinks search box...

sitelinks-search-box/sitelinks-search-box.php 85% from 13 tests

Analyzing the main PHP file in "Sitelinks Search Box" version 1.3
It is important to fix the following:
  • Description: Please don't use more than 140 characters for the plugin description (currently 450 characters long)
  • Text Domain: Please use dashes and lowercase characters for text domains

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
Everything looks great! No dangerous files found in this plugin261 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PO File72274237
PHP182424

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.12
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%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
No PNG files were detected