67% seo-redirection

Code Review | SEO Redirection Plugin - 301 Redirect Manager

WordPress plugin SEO Redirection Plugin - 301 Redirect Manager scored67%from 54 tests.

About plugin

  • Plugin page: seo-redirection
  • Plugin version: 9.5
  • PHP version: 7.4.16
  • WordPress compatibility: 4.1-6.2.2
  • WordPress version: 6.3.1
  • First release: Apr 11, 2014
  • Latest release: Jun 20, 2023
  • Number of updates: 290
  • Update frequency: every 11.6 days
  • Top authors: fakhris (86.21%)osamaesh (13.1%)wp-buy (1.38%)

Code review

54 tests

User reviews

74 reviews

Install metrics

20,000+ active /1,053,159 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼5.11ms] Passed 4 tests

An overview of server-side resources used by SEO Redirection Plugin - 301 Redirect Manager
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.57 ▲0.1141.16 ▲2.55
Dashboard /wp-admin3.40 ▲0.1044.04 ▼7.50
Posts /wp-admin/edit.php3.46 ▲0.1049.27 ▼3.46
Add New Post /wp-admin/post-new.php5.93 ▲0.0490.81 ▼12.04
Media Library /wp-admin/upload.php3.26 ▲0.0338.58 ▲4.42

Server storage [IO: ▲1.74MB] [DB: ▲0.00MB] 67% from 3 tests

How much does this plugin use your filesystem and database?
It is recommended to fix the following issues
  • There were 1 file (0.86KB) illegally modified outside of "wp-content/plugins/seo-redirection/" and "wp-content/uploads/"
    • (modified) .htaccess
Filesystem: 85 new files
Database: 3 new tables, 7 new options
New tables
wp_WP_SEO_404_links
wp_WP_SEO_Cache
wp_WP_SEO_Redirection_LOG
New WordPress options
can_compress_scripts
widget_recent-posts
widget_recent-comments
theysaidso_admin_options
db_upgraded
wp-seo-redirection-group
widget_theysaidso_widget

Browser metrics Passed 4 tests

SEO Redirection Plugin - 301 Redirect Manager: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,835 ▲7414.34 ▲0.142.09 ▲0.4262.12 ▲26.62
Dashboard /wp-admin2,196 ▲225.54 ▼0.0383.53 ▼3.5435.58 ▼6.82
Posts /wp-admin/edit.php2,124 ▲211.99 ▼0.0236.06 ▼2.0441.82 ▲8.40
Add New Post /wp-admin/post-new.php1,542 ▲1621.93 ▼1.20570.10 ▼31.9979.53 ▲23.02
Media Library /wp-admin/upload.php1,404 ▲14.17 ▼0.0399.40 ▼10.3341.90 ▼1.17
SEO Redirection /wp-admin/seo-redirection.php260.420.099.94

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 50% 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 does not fully uninstall, leaving 3 tables in the database
    • wp_WP_SEO_Cache
    • wp_WP_SEO_404_links
    • wp_WP_SEO_Redirection_LOG
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • wp-seo-redirection-group
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
  • 6× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Warning
      require_once(WPSR_PATHcustom/lib/cf.SR_redirect_cache.class.php): failed to open stream: No such file or directory in wp-content/plugins/seo-redirection/options/option_export_import.php on line 3
    • > PHP Fatal error
      require_once(): Failed opening required 'WPSR_PATHcustom/lib/cf.SR_redirect_cache.class.php' (include_path='.:/usr/share/php') in wp-content/plugins/seo-redirection/options/option_export_import.php on line 3
    • > PHP Fatal error
      Uncaught Error: Call to a member function post() on null in wp-content/plugins/seo-redirection/options/option_page_404.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/seo-redirection/seo-redirection.php:16
    • > PHP Fatal error
      Uncaught PDOException: SQLSTATE[HY000] [1045] Access denied for user 'user'@'localhost' (using password: YES) in wp-content/plugins/seo-redirection/custom/export/xml.php:7
    • > PHP Warning
      Use of undefined constant WPSR_PATH - assumed 'WPSR_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/seo-redirection/options/option_export_import.php on line 3

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There are user-side issues you should fix
    • > GET request to /wp-admin/seo-redirection.php
    • > Network (severe)
    wp-admin/seo-redirection.php - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 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
Attributes that require attention:
  • Screenshots: These screenshots require images: #1 (Achieve flawless SEO redirects with ease & Take control of your site's redirects), #2 (List of custom redirections.), #3 (Page to Page custom redirection.), #4 (Folders custom redirection.), #5 (Regular Expression custom redirection.), #6 (Redirected posts via the Redirection Box.), #7 (All redirections history.), #8 (Control panel options.), #9 (Redirection Box in edit page for posts and pages.)
  • Tags: Please reduce the number of tags, currently 24 tag instead of maximum 10
You can look at the official readme.txt

seo-redirection/seo-redirection.php Passed 13 tests

The main file in "SEO Redirection Plugin - 301 Redirect Manager" v. 9.5 serves as a complement to information provided in readme.txt and as the entry point to the plugin
72 characters long description:
By this plugin you can manage all your website redirection types easily.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin14,458 lines of code in 36 files:
LanguageFilesBlank linesComment linesLines of code
CSS51,788489,880
PHP271,4474144,209
JavaScript44935369

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity20.83
▷ Minimum class complexity2.00
▷ Maximum class complexity76.00
Average method complexity2.26
▷ Minimum method complexity1.00
▷ Maximum method complexity48.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes12
▷ Abstract classes00.00%
▷ Concrete classes12100.00%
▷ Final classes00.00%
Methods189
▷ Static methods105.29%
▷ Public methods17089.95%
▷ Protected methods00.00%
▷ Private methods1910.05%
Functions43
▷ Named functions4297.67%
▷ Anonymous functions12.33%
Constants5
▷ Global constants5100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
42 PNG files occupy 1.18MB with 0.42MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
custom/images/circles.png73.38KB73.50KB0.00%
custom/images/control_panel.png41.23KB34.87KB▼ 15.41%
custom/images/404pro.png16.04KB6.97KB▼ 56.56%
screenshot-7.png61.83KB25.57KB▼ 58.64%
common/images/see.png1.28KB0.65KB▼ 49.01%