Conditional Discounts for WooCommerce - A simple yet complete woocommerce dynamic pricing plugin 2.32

Does "Conditional Discounts for WooCommerce - A simple yet complete woocommerce dynamic pricing plugin" work with WordPress 6.4.2 and PHP 8.1.12? A smoke test was performed on .

Summary

Errors
2PHP fatal errors
1JavaScript exceptions
1Page failed to load
  • 1 403 Forbidden
No resource errors
Performance

Memory usage: 89.9 KiB
The average PHP memory usage increased by this amount after activating by the plugin.

Page speed impact: insignificant.
The plugin didn't make the site noticeably slower.

Environment
WordPress version6.4.2
PHP version8.1.12
MySQL version10.6.10
PHP memory limit512M
Plugin Info
Last updated
Active installs 10,000+
WordPress.org page https://wordpress.org/plugins/woo-advanced-discounts/
Badges

WordPress compatibility badge PHP compatibility badge

Get badge code

Pages 4

WordPress › Error

Page screenshot: WordPress › Error
URL /wp-admin/edit.php?post_type=o-discount&page=wad-pro-features
Requested URL /wp-admin/plugins.php?action=activate&plugin=woo-advanced-discounts%2Fwad.php&plugin_status=all&paged=1&s&_wpnonce=3b94336e1b
Aspect after-activation
HTTP status 403
Load time 0.298 s
Memory usage N/A
JS errors None
Resource errors None

Discounts

Page screenshot: Discounts
URL /wp-admin/edit.php?post_type=o-discount
Aspect menu-item
HTTP status 200
Load time 0.273 s
Memory usage 3.44 MiB
JS errors None
Resource errors None

Discounts → New discount

Page screenshot: Discounts → New discount
URL /wp-admin/post-new.php?post_type=o-discount
Aspect menu-item
HTTP status 200
Load time 0.453 s
Memory usage 3.47 MiB
JS errors
[
    {
        "message": "TypeError: $(...).select2 is not a function\n    at HTMLDocument.<anonymous> (/wp-content/plugins/woo-advanced-discounts/admin/js/wad-admin.js?ver=2.32:56:45)\n    at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.4.2:2:27028)\n    at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils&ver=6.4.2:2:27330)",
        "trace": null,
        "code": null
    }
]
Resource errors None

Test site – Just another WordPress site

Page screenshot: Test site – Just another WordPress site
URL /
Aspect front-page
HTTP status 200
Load time 0.213 s
Memory usage N/A
JS errors None
Resource errors None

Benchmark

URL Load time Memory usage
Inactive Active Change Inactive Active Change
/wp-admin/index.php0.348 s0.471 s+0.123 s3.38 MiB3.47 MiB+ 96.28 KiB
/wp-admin/edit.php0.210 s0.315 s+0.105 s3.41 MiB3.5 MiB+ 95.94 KiB
/wp-admin/post-new.php1.013 s0.754 s-0.259 s5.46 MiB5.56 MiB+ 104.78 KiB
/wp-admin/upload.php0.691 s0.578 s-0.113 s3.32 MiB3.4 MiB+ 79.3 KiB
/wp-admin/options-writing.php0.236 s0.332 s+0.096 s3.32 MiB3.39 MiB+ 71.2 KiB
/wp-admin/media-new.php0.343 s0.350 s+0.007 s3.29 MiB3.38 MiB+ 91.12 KiB
/wp-admin/edit-tags.php?taxonomy=category0.211 s0.300 s+0.089 s3.31 MiB3.41 MiB+ 96.31 KiB
/wp-admin/post-new.php?post_type=page0.636 s0.712 s+0.076 s5.45 MiB5.55 MiB+ 104.79 KiB
/wp-admin/options-discussion.php0.352 s0.349 s-0.003 s3.3 MiB3.38 MiB+ 80.98 KiB
/wp-admin/edit-comments.php0.259 s0.328 s+0.069 s3.34 MiB3.41 MiB+ 78.3 KiB
/0.304 s0.162 s-0.142 s3.36 MiB
Average 0.418 s0.423 s+0.004 s3.72 MiB3.85 MiB+ 89.9 KiB

Code Statistics

Note: Third-party libraries and minified JS/CSS files are excluded from these statistics where possible, so the numbers you see here may be lower than those reported by other tools.

PHP
CSS
JavaScript
Language % Lines of code Comment lines Files
PHP35.1%3,6101,05414
CSS31.5%3,2401786
JavaScript25.4%2,6141828
PO File7.8%8033242
SVG0.2%2411
Total 10,291 1,739 31

PHP Code Analysis | More results »

Lines of code 3,614
Total complexity 646
Median class complexity 12.0
Median method complexity 2.0
Most complex class WAD_Discount
Most complex function O_Utils::admin_fields()
Classes 10
Methods 122
Functions 19

Additions

Things that the plugin adds to the site. This section is not intended to be comprehensive. The test tool only looks for a few specific types of added content.

Custom Post Types 2

ID Name
o-listList
o-discountDiscount

Meta Boxes

{
    "o-list": {
        "o-list-settings-box": {
            "title": "List settings",
            "context": "advanced"
        }
    },
    "o-discount": {
        "o-discount-settings-box": {
            "title": "Discount settings",
            "context": "advanced"
        }
    }
}

PHP Error Log 26 lines

[19-Jan-2024 14:59:02 UTC] PHP Fatal error:  Uncaught Error: Call to undefined function is_cart() in /wp-content/plugins/woo-advanced-discounts/includes/class-wad-discount.php:1365
Stack trace:
#0 /wp-includes/class-wp-hook.php(324): WAD_Discount->get_loop_data()
#1 /wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters()
#2 /wp-includes/plugin.php(565): WP_Hook->do_action()
#3 /wp-includes/class-wp-query.php(3683): do_action_ref_array()
#4 /wp-includes/query.php(1005): WP_Query->the_post()
#5 /wp-content/themes/twentyseventeen/index.php(39): the_post()
#6 /wp-includes/template-loader.php(106): include('...')
#7 /wp-blog-header.php(19): require_once('...')
#8 /index.php(17): require('...')
#9 {main}
  thrown in /wp-content/plugins/woo-advanced-discounts/includes/class-wad-discount.php on line 1365
[19-Jan-2024 14:59:12 UTC] PHP Fatal error:  Uncaught Error: Call to undefined function is_cart() in /wp-content/plugins/woo-advanced-discounts/includes/class-wad-discount.php:1365
Stack trace:
#0 /wp-includes/class-wp-hook.php(324): WAD_Discount->get_loop_data()
#1 /wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters()
#2 /wp-includes/plugin.php(565): WP_Hook->do_action()
#3 /wp-includes/class-wp-query.php(3683): do_action_ref_array()
#4 /wp-includes/query.php(1005): WP_Query->the_post()
#5 /wp-content/themes/twentyseventeen/index.php(39): the_post()
#6 /wp-includes/template-loader.php(106): include('...')
#7 /wp-blog-header.php(19): require_once('...')
#8 /index.php(17): require('...')
#9 {main}
  thrown in /wp-content/plugins/woo-advanced-discounts/includes/class-wad-discount.php on line 1365
See also: All tests for this plugin