68% as-woocommerce-with-owl-carousel

Code Review | As woocomerce with owl carousel

WordPress plugin As woocomerce with owl carousel scored68%from 54 tests.

About plugin

  • Plugin page: as-woocommerce-wi...
  • Plugin version: 1.4
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-4.5.2
  • WordPress version: 6.3.1
  • First release: Jul 23, 2015
  • Latest release: Nov 17, 2016
  • Number of updates: 26
  • Update frequency: every 22.0 days
  • Top authors: anuislam (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /5,588 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.90MB] [CPU: ▼33.83ms] Passed 4 tests

A check of server-side resources used by As woocomerce with owl carousel
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0342.55 ▼4.02
Dashboard /wp-admin3.04 ▼0.2625.20 ▼27.03
Posts /wp-admin/edit.php3.04 ▼0.3127.73 ▼25.52
Add New Post /wp-admin/post-new.php3.04 ▼2.8526.86 ▼71.98
Media Library /wp-admin/upload.php3.04 ▼0.1926.00 ▼10.77
As Short code /wp-admin/admin.php?page=as_options3.0428.17
As option /wp-admin/admin.php?page=as_woo_options3.0426.20

Server storage [IO: ▲0.45MB] [DB: ▲0.07MB] Passed 3 tests

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 84 new files
Database: no new tables, 8 new options
New WordPress options
db_upgraded
theysaidso_admin_options
as_woo_owl_all_opt_save
as_woo_owl_all_settings_save
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments

Browser metrics Passed 4 tests

A check of browser resources used by As woocomerce with owl carousel
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,091 ▲33015.28 ▲0.886.22 ▲4.3042.50 ▼0.96
Dashboard /wp-admin2,380 ▲2006.38 ▲0.70115.95 ▲16.1840.91 ▼4.14
Posts /wp-admin/edit.php2,311 ▲2143.57 ▲1.6058.24 ▲22.4136.49 ▲3.58
Add New Post /wp-admin/post-new.php1,564 ▲3823.43 ▲5.96598.12 ▼98.9534.18 ▼23.95
Media Library /wp-admin/upload.php1,445 ▲424.35 ▲0.2186.22 ▼26.6145.15 ▼1.87
As Short code /wp-admin/admin.php?page=as_options2,3643.6154.71138.55
As option /wp-admin/admin.php?page=as_woo_options1,5823.6676.6891.30

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin cannot be uninstalled
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/functions.php+837
    Illegal string offset 'as_woo_checkbox'
  • Zombie WordPress options were found after uninstall: 8 options
    • theysaidso_admin_options
    • db_upgraded
    • as_woo_owl_all_opt_save
    • widget_theysaidso_widget
    • widget_recent-comments
    • as_woo_owl_all_settings_save
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Please fix the following server-side errors
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_woo_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_setting.php+77
    Illegal string offset 'as_woo_checkbox'
  • 105 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_woo_options
    • > Notice in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_setting.php+84
    Uninitialized string offset: 0
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+51
    Illegal string offset 'carousel_name'
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+62
    Illegal string offset 'as_woo_owl_product_type'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+67
    Illegal string offset 'as_woo_owl_product_category'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+81
    Illegal string offset 'items'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+87
    Illegal string offset 'itemsDesktop'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+89
    Illegal string offset 'itemsDesktop_two'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+95
    Illegal string offset 'itemsDesktopSmall_one'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+97
    Illegal string offset 'itemsDesktopSmall_two'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+104
    Illegal string offset 'itemsTablet_one'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+105
    Illegal string offset 'itemsTablet_two'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+114
    Illegal string offset 'itemsTabletSmall'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+122
    Illegal string offset 'itemsMobile_one'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+123
    Illegal string offset 'itemsMobile_two'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+134
    Illegal string offset 'singleItem'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+145
    Illegal string offset 'itemsScaleUp'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+153
    Illegal string offset 'slideSpeed'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+160
    Illegal string offset 'paginationSpeed'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+166
    Illegal string offset 'rewindSpeed'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+175
    Illegal string offset 'autoPlay'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+185
    Illegal string offset 'stopOnHover'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+195
    Illegal string offset 'navigation'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+204
    Illegal string offset 'navigationText_one'
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+206
    Illegal string offset 'navigationText_two'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+215
    Illegal string offset 'rewindNav'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+225
    Illegal string offset 'scrollPerPage'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+235
    Illegal string offset 'pagination'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+245
    Illegal string offset 'paginationNumbers'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+256
    Illegal string offset 'responsive'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+266
    Illegal string offset 'lazyLoad'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+276
    Illegal string offset 'lazyFollow'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+286
    Illegal string offset 'lazyEffect'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+296
    Illegal string offset 'mouseDrag'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+306
    Illegal string offset 'touchDrag'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+316
    Illegal string offset 'afterLazyLoad'
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+326
    Illegal string offset 'as_woo_owl_add_to_cart'
  • 10 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+371
    Illegal string offset 'as_button'
  • 13 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=as_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php+409
    Illegal string offset 'as_select_icon'
    • > GET request to /wp-admin/admin.php?page=as_woo_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_setting.php+38
    Illegal string offset 'loader_gif'
    • > GET request to /wp-admin/admin.php?page=as_woo_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_setting.php+44
    Illegal string offset 'as_atc_loader_gif'
    • > GET request to /wp-admin/admin.php?page=as_woo_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_setting.php+71
    Illegal string offset 'as_woo_width'
    • > GET request to /wp-admin/admin.php?page=as_woo_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_setting.php+73
    Illegal string offset 'as_woo_height'
    • > GET request to /wp-admin/admin.php?page=as_woo_options
    • > Warning in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_setting.php+84
    Illegal string offset 'as_woo_d_limit'

SRP 50% 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
  • 7× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/functions.php:376
    • > PHP Fatal error
      Uncaught Error: Call to undefined function apply_filters() in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/anu_ads.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/as-woocommerce-with-owl-carousel/as-owl-carousel.php:54
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_option.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_shortcode.php:295
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_opt_interface.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/as-woocommerce-with-owl-carousel/inc/as_woo_owl_opt/as_woo_owl_setting.php:4

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need to be fixed:
  • Tags: Too many tags (14 tag instead of maximum 10); only the first 5 tags are used in your directory listing
The official readme.txt might help

as-woocommerce-with-owl-carousel/as-owl-carousel.php 92% from 13 tests

Analyzing the main PHP file in "As woocomerce with owl carousel" version 1.4
It is important to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("as-woocommerce-with-owl-carousel.php" instead of "as-owl-carousel.php")

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
No dangerous file extensions were detected3,439 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript4245211,582
PHP7336331,538
CSS51829319

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.43
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%
Functions26
▷ Named functions26100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
64 PNG files occupy 0.20MB with 0.07MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
ico/right7.png0.53KB0.61KB0.00%
ico/left14.png0.62KB0.63KB0.00%
ico/left3.png0.46KB0.45KB▼ 2.75%
inc/img/fiverr.png27.87KB5.27KB▼ 81.10%
inc/img/github.png16.12KB2.46KB▼ 84.75%