52% countdown-builder

Code Review | Countdown, Coming Soon, Maintenance - Countdown & Clock

WordPress plugin Countdown, Coming Soon, Maintenance - Countdown & Clock scored52%from 54 tests.

About plugin

  • Plugin page: countdown-builder
  • Plugin version: 2.6.9
  • PHP compatiblity: 5.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.8-6.4
  • WordPress version: 6.3.1
  • First release: Feb 11, 2018
  • Latest release: Nov 22, 2023
  • Number of updates: 430
  • Update frequency: every 4.9 days
  • Top authors: adamskaat (99.77%)

Code review

54 tests

User reviews

165 reviews

Install metrics

10,000+ active /673,418 total downloads

Benchmarks

Plugin footprint 47% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.40MB] [CPU: ▼32.64ms] Passed 4 tests

A check of server-side resources used by Countdown, Coming Soon, Maintenance - Countdown & Clock
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /4.37 ▲0.9122.28 ▼18.30
Dashboard /wp-admin4.42 ▲1.1127.64 ▼21.54
Posts /wp-admin/edit.php4.42 ▲1.0626.36 ▼22.04
Add New Post /wp-admin/post-new.php4.42 ▼1.4728.83 ▼68.67
Media Library /wp-admin/upload.php4.42 ▲1.1924.43 ▼13.01
Tutorials /wp-admin/edit.php?post_type=ycdcountdown&page=ycdTutorials4.4225.25
More Plugins /wp-admin/edit.php?post_type=ycdcountdown&page=ycdPlugins4.4235.74
Subscribers Pro /wp-admin/edit.php?post_type=ycdcountdown&page=ycdSubscribers4.4224.96
Countdown Types /wp-admin/edit.php?post_type=ycdcountdown&page=ycdcountdown4.4223.33
Newsletter Pro /wp-admin/edit.php?post_type=ycdcountdown&page=ycdNewsletter4.4223.87
Coming Soon /wp-admin/edit.php?post_type=ycdcountdown&page=ycdComingSoon4.4224.82
All Countdown & Clock /wp-admin/edit.php?post_type=ycdcountdown4.4225.06
Settings /wp-admin/edit.php?post_type=ycdcountdown&page=ycdSettings4.4224.10
Support /wp-admin/edit.php?post_type=ycdcountdown&page=supports4.4226.10
Add New /wp-admin/post-new.php?post_type=ycdcountdown4.4223.60

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

Filesystem and database footprint
The plugin installed successfully
Filesystem: 172 new files
Database: 1 new table, 13 new options
New tables
wp_ycd_subscribers
New WordPress options
db_upgraded
widget_ycd_countdown_widget
widget_recent-posts
widget_recent-comments
YcdInstallDate
can_compress_scripts
widget_theysaidso_widget
YcdUsageDays
recovery_mode_email_last_sent
YcdShowNextTime
...

Browser metrics 50% from 4 tests

A check of browser resources used by Countdown, Coming Soon, Maintenance - Countdown & Clock
You may want to improve the following
  • Memory: In order to improve user experience, please limit browser memory usage to 75.00MB (currently 112.01MB on /wp-admin/edit.php?post_type=ycdcountdown&page=ycdTutorials)
  • Script duration: Total JavaScript execution time should be lower than 1,500.00ms (currently 2,909.95ms on /wp-admin/edit.php?post_type=ycdcountdown&page=ycdTutorials)
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,925 ▲16314.34 ▼0.421.91 ▲0.0647.42 ▼4.77
Dashboard /wp-admin2,311 ▲1315.66 ▼0.0498.00 ▼0.8057.64 ▲11.95
Posts /wp-admin/edit.php2,228 ▲1282.20 ▲0.2438.74 ▼2.6251.88 ▲12.81
Add New Post /wp-admin/post-new.php6,315 ▲4,78918.97 ▼2.54873.02 ▲198.7039.68 ▼20.90
Media Library /wp-admin/upload.php1,513 ▲1134.20 ▼0.0397.60 ▼7.8054.94 ▲7.52
Tutorials /wp-admin/edit.php?post_type=ycdcountdown&page=ycdTutorials10,326112.012,909.95117.81
More Plugins /wp-admin/edit.php?post_type=ycdcountdown&page=ycdPlugins1,1524.4595.9534.36
Subscribers Pro /wp-admin/edit.php?post_type=ycdcountdown&page=ycdSubscribers8513.5734.6426.58
Countdown Types /wp-admin/edit.php?post_type=ycdcountdown&page=ycdcountdown1,3094.2749.7952.88
Newsletter Pro /wp-admin/edit.php?post_type=ycdcountdown&page=ycdNewsletter9324.2450.3729.17
Coming Soon /wp-admin/edit.php?post_type=ycdcountdown&page=ycdComingSoon5,0577.97260.55102.71
All Countdown & Clock /wp-admin/edit.php?post_type=ycdcountdown1,8024.5157.6440.50
Settings /wp-admin/edit.php?post_type=ycdcountdown&page=ycdSettings1,2134.7564.8029.73
Support /wp-admin/edit.php?post_type=ycdcountdown&page=supports1,1514.2050.2651.63
Add New /wp-admin/post-new.php?post_type=ycdcountdown19,72517.99743.28231.73

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin cannot be uninstalled
    • > Notice in wp-content/plugins/countdown-builder/classes/RegisterPostType.php+55
    Undefined index: post
  • Zombie tables detected upon uninstall: 1 table
    • wp_ycd_subscribers
  • The uninstall procedure has failed, leaving 12 options in the database
    • widget_recent-comments
    • widget_recent-posts
    • YcdInstallDate
    • can_compress_scripts
    • YcdShowNextTime
    • widget_theysaidso_widget
    • YcdInserted
    • YcdUsageDays
    • db_upgraded
    • widget_ycd_countdown_widget
    • ...

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Almost there, just fix the following server-side errors
  • 25 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/assets/views/admin/shortcodeMetabox.php+9
    Undefined index: post
    • > GET request to /wp-admin/edit.php?post_type=ycdcountdown&page=ycdSubscribers
    • > Warning in wp-content/plugins/countdown-builder/classes/RegisterPostType.php+243
    require_once(wp-content/plugins/countdown-builder//assets/views/subscribers.php): failed to open stream: No such file or directory
    • > GET request to /wp-admin/edit.php?post_type=ycdcountdown&page=ycdSubscribers
    • > Compile error in wp-content/plugins/countdown-builder/classes/RegisterPostType.php+243
    require_once(): Failed opening required 'wp-content/plugins/countdown-builder//assets/views/subscribers.php' (include_path='.:/usr/share/php')
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=ycdcountdown&page=ycdNewsletter
    • > Warning in wp-includes/pluggable.php+1438
    Cannot modify header information - headers already sent by (output started at wp-includes/script-loader.php:2838)
    • > GET request to /wp-admin/edit.php?post_type=ycdcountdown
    • > POST request to /wp-admin/admin-ajax.php
    • > Notice in wp-content/plugins/countdown-builder/classes/RegisterPostType.php+56
    Undefined index: post_type
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/assets/views/generalOptions.php+63
    Undefined index: idAndTitle
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/assets/views/generalOptions.php+75
    Undefined index:
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/assets/views/generalOptions.php+338
    Undefined index: week-days
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/assets/views/countdownButton.php+166
    Undefined index: hover-animation
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/classes/translation/AbstractTranslationManager.php+56
    Undefined index: language
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/classes/translation/AbstractTranslationManager.php+64
    Undefined index: Years
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/classes/translation/AbstractTranslationManager.php+64
    Undefined index: Months
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/classes/translation/AbstractTranslationManager.php+64
    Undefined index: Days
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/classes/translation/AbstractTranslationManager.php+64
    Undefined index: Hours
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/classes/translation/AbstractTranslationManager.php+64
    Undefined index: Minutes
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/classes/translation/AbstractTranslationManager.php+64
    Undefined index: Seconds
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/classes/countdown/Countdown.php+1142
    Trying to access array offset on value of type null
    • > GET request to /wp-admin/post-new.php?post_type=ycdcountdown
    • > Notice in wp-content/plugins/countdown-builder/classes/countdown/CircleCountdown.php+182
    Undefined index: HTTP_ACCEPT_LANGUAGE

SRP 0% 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
Almost there! Just fix the following items
  • 2× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/countdown-builder/assets/views/upgrade.php
    • > /wp-content/plugins/countdown-builder/assets/views/admin/moreIdeas.php
  • 83× PHP files trigger errors when accessed directly with GET requests (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_die() in wp-content/plugins/countdown-builder/countdown-builder.php:13
    • > PHP Warning
      Use of undefined constant YCD_FREE_VERSION - assumed 'YCD_FREE_VERSION' (this will throw an Error in a future version of PHP) in wp-content/plugins/countdown-builder/classes/countdown/CircleCountdown.php on line 3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function admin_url() in wp-content/plugins/countdown-builder/config/config.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/countdown-builder/assets/views/supportMetabox.php:7
    • > PHP Warning
      Use of undefined constant YCD_FREE_VERSION - assumed 'YCD_FREE_VERSION' (this will throw an Error in a future version of PHP) in wp-content/plugins/countdown-builder/assets/views/cricleMainView.php on line 6
    • > PHP Warning
      require_once(YCD_CLASSES_PATH/translation/TranslationManager.php): failed to open stream: No such file or directory in wp-content/plugins/countdown-builder/assets/views/translations/circleTranslation.php on line 4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/countdown-builder/assets/views/subscriptionSection.php:7
    • > PHP Fatal error
      Uncaught Error: Class 'ycd\\AdminHelper' not found in wp-content/plugins/countdown-builder/assets/views/front/comingSoonTempleate.php:4
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/countdown-builder/assets/views/main/sticky_sub_options/stickyTextSettings.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/countdown-builder/assets/views/admin/uninstallSurveyPopup.php:27

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Attributes that require attention:
  • Screenshots: Please add descriptions for these screenshots #1, #10, #11, #12, #13, #14, #15, #16, #17, #18, #19, #2, #3, #4, #5, #6, #7, #8, #9 in countdown-builder/assets to your readme.txt
You can look at the official readme.txt

countdown-builder/countdown-builder.php Passed 13 tests

The main PHP file in "Countdown, Coming Soon, Maintenance - Countdown & Clock" ver. 2.6.9 adds more information about the plugin and also serves as the entry point for this plugin
39 characters long description:
The best countdown plugin by Adam skaat

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
There were no executable files found in this plugin27,220 lines of code in 122 files:
LanguageFilesBlank linesComment linesLines of code
PHP881,37328212,451
JavaScript202,22951810,459
CSS13249764,309
SVG1001

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.15
Average class complexity16.21
▷ Minimum class complexity1.00
▷ Maximum class complexity115.00
Average method complexity2.22
▷ Minimum method complexity1.00
▷ Maximum method complexity36.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes39
▷ Abstract classes25.13%
▷ Concrete classes3794.87%
▷ Final classes00.00%
Methods484
▷ Static methods9619.83%
▷ Public methods40984.50%
▷ Protected methods40.83%
▷ Private methods7114.67%
Functions3
▷ Named functions133.33%
▷ Anonymous functions266.67%
Constants5
▷ Global constants5100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
33 PNG files occupy 0.52MB with 0.31MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/css/jQueryDialog/images/ui-bg_diagonal-maze_20_6e4f1c_10x10.png0.18KB0.11KB▼ 38.25%
assets/img/clock6.png37.21KB11.01KB▼ 70.41%
assets/img/simpleCountdown.png14.14KB4.83KB▼ 65.81%
assets/img/clock1.png14.84KB4.76KB▼ 67.90%
assets/css/jQueryDialog/images/ui-bg_fine-grain_15_ffffff_60x60.png3.63KB1.56KB▼ 56.97%