77% wp-seopress

Code Review | SEOPress - On-site SEO

WordPress plugin SEOPress - On-site SEO scored77%from 54 tests.

About plugin

  • Plugin page: wp-seopress
  • Plugin version: 7.2
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.4
  • WordPress version: 6.3.1
  • First release: Aug 22, 2016
  • Latest release: Nov 15, 2023
  • Number of updates: 652
  • Update frequency: every 4.1 days
  • Top authors: rainbowgeek (100%)

Code review

54 tests

User reviews

938 reviews

Install metrics

200,000+ active /10,130,341 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲4.39MB] [CPU: ▲28.91ms] 75% from 4 tests

Server-side resources used by SEOPress - On-site SEO
Please take the time to fix the following items
  • CPU: You should keep total CPU usage under 500.00ms (currently 1,139.96ms on /wp-admin/admin.php?page=seopress-option)
PageMemory (MB)CPU Time (ms)
Home /7.42 ▲3.9576.00 ▲37.14
Dashboard /wp-admin7.80 ▲4.4584.16 ▲22.28
Posts /wp-admin/edit.php8.25 ▲4.9088.52 ▲42.81
Add New Post /wp-admin/post-new.php10.63 ▲4.74119.00 ▲21.33
Media Library /wp-admin/upload.php7.64 ▲4.4165.31 ▲34.87
Analytics /wp-admin/admin.php?page=seopress-google-analytics7.6362.26
Social Networks /wp-admin/admin.php?page=seopress-social7.6563.85
Advanced /wp-admin/admin.php?page=seopress-advanced7.6364.42
Tools /wp-admin/admin.php?page=seopress-import-export7.6561.06
XML - HTML Sitemap /wp-admin/admin.php?page=seopress-xml-sitemap7.6361.94
Instant Indexing /wp-admin/admin.php?page=seopress-instant-indexing8.2765.82
Titles & Metas /wp-admin/admin.php?page=seopress-titles7.6365.25
Dashboard /wp-admin/admin.php?page=seopress-option8.801,139.96

Server storage [IO: ▲7.41MB] [DB: ▲0.08MB] Passed 3 tests

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 1,196 new files
Database: no new tables, 13 new options
New WordPress options
seopress_activated
widget_recent-comments
seopress_toggle
theysaidso_admin_options
db_upgraded
seopress_titles_option_name
widget_theysaidso_widget
seopress_instant_indexing_option_name
seopress_xml_sitemap_option_name
seopress_advanced_option_name
...

Browser metrics Passed 4 tests

Checking browser requirements for SEOPress - On-site SEO
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,982 ▲23514.38 ▲0.021.86 ▲0.1843.92 ▲0.19
Dashboard /wp-admin2,313 ▲1335.66 ▼0.0295.63 ▲3.8543.49 ▼6.17
Posts /wp-admin/edit.php2,469 ▲3722.05 ▲0.0938.77 ▲1.2239.60 ▲6.44
Add New Post /wp-admin/post-new.php3,442 ▲1,91219.74 ▼3.39706.52 ▲67.96132.01 ▲76.01
Media Library /wp-admin/upload.php1,515 ▲1154.21 ▲0.03101.74 ▲3.5240.91 ▲0.42
Analytics /wp-admin/admin.php?page=seopress-google-analytics4,6574.55141.7255.85
Social Networks /wp-admin/admin.php?page=seopress-social2,3913.4854.2895.37
Advanced /wp-admin/admin.php?page=seopress-advanced2,9692.0541.8749.22
Tools /wp-admin/admin.php?page=seopress-import-export2,5411.9529.8342.44
XML - HTML Sitemap /wp-admin/admin.php?page=seopress-xml-sitemap2,0501.8629.5547.96
Instant Indexing /wp-admin/admin.php?page=seopress-instant-indexing1,8461.9133.4148.93
Titles & Metas /wp-admin/admin.php?page=seopress-titles5,1092.2936.0758.85
Dashboard /wp-admin/admin.php?page=seopress-option2,4572.3429.9663.56

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 12 options in the database
    • seopress_titles_option_name
    • widget_recent-comments
    • can_compress_scripts
    • seopress_xml_sitemap_option_name
    • theysaidso_admin_options
    • seopress_advanced_option_name
    • seopress_instant_indexing_option_name
    • widget_recent-posts
    • seopress_toggle
    • seopress_social_option_name
    • ...

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% 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
  • 141× PHP files output text when accessed directly (only 10 are shown):
    • > /wp-content/plugins/wp-seopress/inc/admin/sections/InstantIndexing.php
    • > /wp-content/plugins/wp-seopress/inc/functions/sitemap/template-html-sitemap.php
    • > /wp-content/plugins/wp-seopress/src/Services/ContentAnalysis/GetContent/LinkNoFollow.php
    • > /wp-content/plugins/wp-seopress/inc/admin/metaboxes/admin-metaboxes-content-analysis-form.php
    • > /wp-content/plugins/wp-seopress/inc/functions/sitemap/template-xml-sitemaps-xsl.php
    • > /wp-content/plugins/wp-seopress/src/Services/ContentAnalysis/GetContent/Schema.php
    • > /wp-content/plugins/wp-seopress/src/Services/Options/DashboardOption.php
    • > /wp-content/plugins/wp-seopress/seopress.php
    • > /wp-content/plugins/wp-seopress/src/Services/Options/ToggleOption.php
    • > /wp-content/plugins/wp-seopress/inc/functions/options-sitemap.php
  • 367× PHP files trigger server errors when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Interface 'Psr\\Http\\Message\\StreamInterface' not found in wp-content/plugins/wp-seopress/vendor/guzzlehttp/psr7/src/LimitStream.php:12
    • > PHP Fatal error
      Uncaught Error: Class 'phpseclib3\\Math\\Common\\FiniteField' not found in wp-content/plugins/wp-seopress/vendor/phpseclib/phpseclib/phpseclib/Math/BinaryField.php:26
    • > PHP Fatal error
      Uncaught Error: Interface 'Monolog\\Handler\\HandlerInterface' not found in wp-content/plugins/wp-seopress/vendor/monolog/monolog/src/Monolog/Handler/HandlerWrapper.php:34
    • > PHP Fatal error
      Uncaught Error: Class 'phpseclib3\\Crypt\\Common\\Formats\\Keys\\PKCS8' not found in wp-content/plugins/wp-seopress/vendor/phpseclib/phpseclib/phpseclib/Crypt/DH/Formats/Keys/PKCS8.php:32
    • > PHP Warning
      Class 'Google\\AuthHandler\\Guzzle6AuthHandler' not found in wp-content/plugins/wp-seopress/vendor/google/apiclient/src/aliases.php on line 33
    • > PHP Fatal error
      Uncaught Error: Interface 'MatthiasMullie\\PathConverter\\ConverterInterface' not found in wp-content/plugins/wp-seopress/vendor/matthiasmullie/path-converter/src/Converter.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'phpseclib3\\Crypt\\EC\\BaseCurves\\Binary' not found in wp-content/plugins/wp-seopress/vendor/phpseclib/phpseclib/phpseclib/Crypt/EC/Curves/sect409k1.php:19
    • > PHP Warning
      Class 'Google\\Http\\MediaFileUpload' not found in wp-content/plugins/wp-seopress/vendor/google/apiclient/src/aliases.php on line 33
    • > PHP Fatal error
      Uncaught Error: Class 'phpseclib3\\Crypt\\Common\\Formats\\Keys\\PKCS1' not found in wp-content/plugins/wp-seopress/vendor/phpseclib/phpseclib/phpseclib/Crypt/RSA/Formats/Keys/PKCS1.php:36
    • > PHP Fatal error
      Uncaught Error: Class 'phpseclib3\\Crypt\\EC\\BaseCurves\\TwistedEdwards' not found in wp-content/plugins/wp-seopress/vendor/phpseclib/phpseclib/phpseclib/Crypt/EC/Curves/Ed448.php:20

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 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention:
  • Requires at least: Invalid plugin version format
  • Tags: You are using too many tags: 12 tag instead of maximum 10
You can look at the official readme.txt

wp-seopress/seopress.php 92% from 13 tests

The main PHP file in "SEOPress - On-site SEO" ver. 7.2 adds more information about the plugin and also serves as the entry point for this plugin
The following require your attention:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("wp-seopress.php" instead of "seopress.php")

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
There were no executable files found in this plugin109,457 lines of code in 1,148 files:
LanguageFilesBlank linesComment linesLines of code
PHP99219,30443,94692,059
Markdown352,13605,827
CSS16910375,537
JavaScript434161343,369
JSON27002,483
XML320135
SVG310044
Bourne Shell1203

PHP code 50% from 2 tests

A short review of cyclomatic complexity and code structure
Please fix the following
  • Please reduce cyclomatic complexity of methods to less than 100 (currently 104)
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity12.27
▷ Minimum class complexity1.00
▷ Maximum class complexity679.00
Average method complexity3.41
▷ Minimum method complexity1.00
▷ Maximum method complexity104.00
Code structure
Namespaces133
Interfaces60
Traits17
Classes814
▷ Abstract classes23328.62%
▷ Concrete classes58171.38%
▷ Final classes6611.36%
Methods4,202
▷ Static methods79518.92%
▷ Public methods3,21476.49%
▷ Protected methods48611.57%
▷ Private methods50211.95%
Functions745
▷ Named functions54473.02%
▷ Anonymous functions20126.98%
Constants634
▷ Global constants223.47%
▷ Class constants61296.53%
▷ Public constants57493.79%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There are no PNG files in this plugin