78% multilanguage

Code Review | Multilanguage by BestWebSoft - WordPress Translation Plugin and Language Switcher

WordPress plugin Multilanguage by BestWebSoft - WordPress Translation Plugin and Language Switcher scored78%from 54 tests.

About plugin

  • Plugin page: multilanguage
  • Plugin version: 1.4.4
  • PHP version: 7.4.16
  • WordPress compatibility: 5.6-6.4
  • WordPress version: 6.3.1
  • First release: Oct 24, 2014
  • Latest release: Nov 16, 2023
  • Number of updates: 59
  • Update frequency: every 56.1 days
  • Top authors: bestwebsoft (100%)

Code review

54 tests

User reviews

89 reviews

Install metrics

5,000+ active /238,627 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.19MB] [CPU: ▼1.92ms] Passed 4 tests

Server-side resources used by Multilanguage by BestWebSoft - WordPress Translation Plugin and Language Switcher
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.65 ▲0.1846.38 ▲5.04
Dashboard /wp-admin3.52 ▲0.1850.28 ▼12.90
Posts /wp-admin/edit.php3.60 ▲0.2560.27 ▲14.51
Add New Post /wp-admin/post-new.php6.11 ▲0.2396.74 ▼3.93
Media Library /wp-admin/upload.php3.41 ▲0.1837.67 ▲4.10
Settings /wp-admin/admin.php?page=mltlngg_settings3.8642.51
BWS Panel /wp-admin/admin.php?page=mltlngg-bws-panel3.4038.29

Server storage [IO: ▲10.10MB] [DB: ▲0.01MB] Passed 3 tests

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 315 new files
Database: 2 new tables, 9 new options
New tables
wp_mltlngg_translate
wp_mltlngg_terms_translate
New WordPress options
widget_multi_language_widget
widget_recent-posts
db_upgraded
theysaidso_admin_options
bstwbsftwppdtplgns_options
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts
mltlngg_options

Browser metrics Passed 4 tests

Checking browser requirements for Multilanguage by BestWebSoft - WordPress Translation Plugin and Language Switcher
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,853 ▲9114.34 ▼0.011.63 ▼0.0438.19 ▼4.70
Dashboard /wp-admin2,256 ▲855.62 ▲0.0298.00 ▼1.0545.53 ▲1.95
Posts /wp-admin/edit.php2,272 ▲1722.29 ▲0.2941.84 ▲6.4440.98 ▲1.55
Add New Post /wp-admin/post-new.php11,182 ▲9,65624.66 ▲1.471,305.58 ▲551.9356.20 ▼4.87
Media Library /wp-admin/upload.php1,462 ▲654.26 ▲0.01117.38 ▲16.9048.45 ▲7.20
Languages /wp-admin/multilanguage-languages.php260.410.1114.43
Settings /wp-admin/admin.php?page=mltlngg_settings2,4244.14106.1772.31
BWS Panel /wp-admin/admin.php?page=mltlngg-bws-panel2,8432.0437.4373.08

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not an exhaustive test

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
Almost there! Just fix the following items
  • 6× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/multilanguage/bws_menu/product_list.php:9
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/multilanguage/bws_menu/class-bws-settings.php:1452
    • > PHP Fatal error
      Uncaught Error: Class 'Bws_Settings_Tabs' not found in wp-content/plugins/multilanguage/includes/class-mltlngg-settings.php:6
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/multilanguage/includes/table.php on line 2
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/multilanguage/includes/table.php on line 2
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/multilanguage/multilanguage.php:1238

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Please fix the following user-side errors
    • > GET request to /wp-admin/multilanguage-languages.php
    • > Network (severe)
    wp-admin/multilanguage-languages.php - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/admin.php?page=mltlngg-bws-panel
    • > Network (severe)
    http://ps.w.org/custom-admin-page/assets/icon-256x256.png - 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 undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
Attributes that require attention:
  • Tags: There are too many tags (12 tag instead of maximum 10)
  • Screenshots: Please add images for these screenshots: #1 (Language switcher widget in the frontend.), #2 (Language switcher in the site menu.), #3 (Plugin settings page.), #4 (Plugin languages page.), #5 (Edit language page.), #6 (Post/page editor (Gutenberg).), #7 (Post/page editor with translation tabs (Classic Editor).), #8 (Translation form for adding a new category.), #9 (Translation form for editing a category.), #10 (Translation form for adding a new tag.), #11 (Adding and configuring language switcher widget in the admin panel.), #12 (Adding language switcher into site menu.)
The official readme.txt might help

multilanguage/multilanguage.php Passed 13 tests

The primary PHP file in "Multilanguage by BestWebSoft - WordPress Translation Plugin and Language Switcher" version 1.4.4 is used by WordPress to initiate all plugin functionality
119 characters long description:
Translate WordPress website content to other languages manually. Create multilingual pages, posts, widgets, menus, etc.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
There were no executable files found in this plugin77,141 lines of code in 53 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript112,03619546,441
PO File196,80811,85316,841
PHP118358968,005
CSS81572575,704
SVG400150

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.63
Average class complexity57.20
▷ Minimum class complexity10.00
▷ Maximum class complexity210.00
Average method complexity7.69
▷ Minimum method complexity1.00
▷ Maximum method complexity79.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods42
▷ Static methods12.38%
▷ Public methods3685.71%
▷ Protected methods00.00%
▷ Private methods614.29%
Functions145
▷ Named functions145100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
237 compressed PNG files occupy 5.37MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/flags/szl.png0.27KB0.45KB0.00%
images/flags/sv_SE.png0.38KB0.36KB▼ 4.87%
images/flags/gd.png0.53KB0.52KB▼ 2.38%
images/flags/jv_ID.png0.26KB0.42KB0.00%
images/flags/uz_UZ.png0.34KB0.56KB0.00%