78% card-elements-for-elementor

Code Review | Card Elements for Elementor

WordPress plugin Card Elements for Elementor scored78%from 54 tests.

About plugin

  • Plugin page: card-elements-for...
  • Plugin version: 1.1.9
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-6.3.1
  • WordPress version: 6.3.1
  • First release: Jan 31, 2019
  • Latest release: Oct 5, 2023
  • Number of updates: 15
  • Update frequency: every 113.9 days
  • Top authors: techeshta (100%)

Code review

54 tests

User reviews

10 reviews

Install metrics

4,000+ active /45,090 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.03MB] [CPU: ▼8.62ms] Passed 4 tests

Server-side resources used by Card Elements for Elementor
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0537.91 ▼8.14
Dashboard /wp-admin3.35 ▲0.0050.86 ▼13.57
Posts /wp-admin/edit.php3.40 ▲0.0453.73 ▲4.20
Add New Post /wp-admin/post-new.php5.93 ▲0.0492.94 ▼14.99
Media Library /wp-admin/upload.php3.27 ▲0.0438.25 ▲2.22

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 29 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
theysaidso_admin_options
db_upgraded
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for Card Elements for Elementor
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,854 ▲6814.73 ▲0.571.85 ▼0.2341.63 ▼2.82
Dashboard /wp-admin2,205 ▲285.50 ▼0.0389.86 ▼12.2737.73 ▼5.54
Posts /wp-admin/edit.php2,110 ▲102.15 ▲0.1739.82 ▼0.5737.91 ▲1.42
Add New Post /wp-admin/post-new.php1,545 ▲1718.32 ▼4.68634.16 ▼39.1980.91 ▲28.71
Media Library /wp-admin/upload.php1,404 ▲44.20 ▲0.0197.99 ▼8.8442.17 ▲0.53

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments

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
Everything seems fine, however this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
  • 10× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/card-elements-for-elementor/include/profile-card/elementor-profile-card-4.php
    • > /wp-content/plugins/card-elements-for-elementor/include/profile-card/elementor-profile-card-3.php
    • > /wp-content/plugins/card-elements-for-elementor/include/profile-card/elementor-profile-card-11.php
    • > /wp-content/plugins/card-elements-for-elementor/include/post-card/elementor-post-card-pro.php
    • > /wp-content/plugins/card-elements-for-elementor/include/profile-card/elementor-profile-card-2.php
    • > /wp-content/plugins/card-elements-for-elementor/include/testimonial-card/elementor-testimonial-card-2.php
    • > /wp-content/plugins/card-elements-for-elementor/include/profile-card/elementor-profile-card-1.php
    • > /wp-content/plugins/card-elements-for-elementor/include/profile-card/elementor-profile-card-5.php
    • > /wp-content/plugins/card-elements-for-elementor/include/testimonial-card/elementor-testimonial-card-6.php
    • > /wp-content/plugins/card-elements-for-elementor/include/testimonial-card/elementor-testimonial-card-1.php
  • 108× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/card-elements-for-elementor/include/post-card/elementor-post-card-1.php on line 8
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/card-elements-for-elementor/include/testimonial-card/elementor-testimonial-card-6.php on line 4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/card-elements-for-elementor/include/profile-card/elementor-profile-card-pro.php:3
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/card-elements-for-elementor/include/profile-card/elementor-profile-card-11.php on line 6
    • > PHP Notice
      Undefined variable: settings in wp-content/plugins/card-elements-for-elementor/include/testimonial-card/elementor-testimonial-card-6.php on line 4
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/card-elements-for-elementor/include/profile-card/elementor-profile-card-2.php on line 5
    • > PHP Notice
      Undefined variable: settings in wp-content/plugins/card-elements-for-elementor/include/testimonial-card/elementor-testimonial-card-6.php on line 8
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/card-elements-for-elementor/include/testimonial-card/elementor-testimonial-card-6.php on line 7
    • > PHP Notice
      Undefined variable: settings in wp-content/plugins/card-elements-for-elementor/include/profile-card/elementor-profile-card-1.php on line 2
    • > PHP Notice
      Undefined variable: settings in wp-content/plugins/card-elements-for-elementor/include/testimonial-card/elementor-testimonial-card-2.php on line 11

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that require attention:
  • Tags: Please delete some tags, you are using 12 tag instead of maximum 10
You can take inspiration from this readme.txt

card-elements-for-elementor/card-elements-for-elementor.php Passed 13 tests

"Card Elements for Elementor" version 1.1.9's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
123 characters long description:
Showcase useful card elements like display team profiles, testimonials and post with card style for Elementor page builder.

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
Good job! No executable or dangerous file extensions detected7,123 lines of code in 26 files:
LanguageFilesBlank linesComment linesLines of code
CSS51,519354,265
PHP213762202,858

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity15.67
▷ Minimum class complexity14.00
▷ Maximum class complexity17.00
Average method complexity3.20
▷ Minimum method complexity1.00
▷ Maximum method complexity17.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods20
▷ Static methods00.00%
▷ Public methods1260.00%
▷ Protected methods840.00%
▷ Private methods00.00%
Functions21
▷ Named functions21100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.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
1 PNG file occupies 0.08MB with 0.05MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/banner-pro.png82.98KB36.86KB▼ 55.58%