PluginProbe
CoolClock / 4.1
CoolClock v4.1
4.3.9 4.3.8 trunk 0.1 2.0 2.9.8 3.0 3.1 3.2 3.3 4.0 4.1 4.2 4.3.3 4.3.4 4.3.5 4.3.6 4.3.7
← All changes | coolclock.php +25 -2 4.24.1 View file →
@@ -4,9 +4,9 @@
4 4 Plugin URI: https://status301.net/wordpress-plugins/coolclock/
5 5 Description: Add an analog clock to your sidebar.
6 6 Text Domain: coolclock
7 7 Domain Path: languages
8 -Version: 4.2
8 +Version: 4.1
9 9 Author: RavanH
10 10 Author URI: https://status301.net/
11 11 */
12 12
@@ -20,8 +20,31 @@
20 20 require plugin_dir_path( __FILE__ ) . '/includes/class-coolclock-widget.php';
21 21 require plugin_dir_path( __FILE__ ) . '/includes/class-coolclock-shortcode.php';
22 22
23 23 /**************
24 + * HOOKS
25 + **************/
26 +
27 +// text domain
28 +add_action( 'plugins_loaded', array( 'CoolClock', 'textdomain' ) );
29 +
30 +// widgets
31 +add_action( 'widgets_init', array( 'CoolClock', 'register_widget' ) );
32 +
33 +// enqueue scripts but only if shortcode or widget has been used
34 +// so it has to be done as late as the wp_footer action
35 +add_action( 'wp_footer', array( 'CoolClock', 'enqueue_scripts' ), 1 );
36 +
37 +/**************
38 + * SHORTCODE
39 + **************/
40 +
41 +add_shortcode( 'coolclock', array( 'CoolClock_Shortcode', 'handle_shortcode' ) );
42 +
43 +// prevent texturizing shortcode content
44 +add_filter( 'no_texturize_shortcodes', array( 'CoolClock_Shortcode', 'no_wptexturize') );
45 +
46 +/**************
24 47 * INITIATE
25 48 **************/
26 49
27 -new CoolClock( __FILE__, '4.2' );
50 +new CoolClock( __FILE__ );