PluginProbe
Customify / 2.2.0
Customify v2.2.0
2.10.9 1.2.3 1.2.4 1.2.5 1.2.6 1.2.7 1.2.7.1 1.3.0 1.3.1 1.4.0 1.4.1 1.4.2 1.5.0 1.5.1 1.5.2 1.5.3 1.5.4 1.5.5 1.5.6 1.5.7 1.6.0 1.6.0.1 1.6.5 1.7.0 1.7.1 All 77 releases
← All changes | features/class-CSS_Editor.php +13 -13 1.3.12.2.0 View file →
@@ -12,16 +12,16 @@
12 12 protected function __construct() {
13 13
14 14 add_action( 'customify_create_custom_control', array( $this, 'cle_create_custom_control' ), 10, 1 );
15 15 add_action( 'customize_controls_enqueue_scripts', array( $this, 'enqueue_admin_customizer_styles' ), 10 );
16 - $load_location = PixCustomifyPlugin::get_plugin_option( 'style_resources_location', 'wp_head' );
16 + $load_location = PixCustomifyPlugin()->get_plugin_setting( 'style_resources_location', 'wp_head' );
17 17
18 18 if ( function_exists( 'wp_custom_css_cb' ) ) {
19 - remove_action( 'wp_head', 'wp_custom_css_cb', 11 );
20 - add_action( $load_location, 'wp_custom_css_cb', 999999999 );
19 +// remove_action( 'wp_head', 'wp_custom_css_cb', 101 );
20 +// add_action( $load_location, 'wp_custom_css_cb', 999999999 );
21 21 } else {
22 22 // keep this for wordpress versions lower than 4.7
23 - add_action( $load_location, array( $this, 'output_dynamic_style' ), 999999999 );
23 + add_action( $load_location, array( $this, 'output_dynamic_style' ), 99 );
24 24 }
25 25
26 26 //Check the WordPress version and if there are known problems disable it
27 27 add_filter( 'customify_css_live_editor_enabled', array( $this, 'disable_if_wp_incompatible' ), 10, 1 );
@@ -34,9 +34,9 @@
34 34 */
35 35 public static function get_instance() {
36 36
37 37 // If the single instance hasn't been set, set it now.
38 - if ( null == self::$instance ) {
38 + if ( is_null( self::$instance ) ) {
39 39 self::$instance = new self;
40 40 }
41 41
42 42 return self::$instance;
@@ -62,9 +62,9 @@
62 62
63 63 // port CSS if
64 64 if ( function_exists( 'wp_update_custom_css_post' ) ) {
65 65 // Migrate any existing theme CSS to the core option added in WordPress 4.7.
66 - $store_type = PixCustomifyPlugin::get_plugin_option( 'values_store_mod', 'option' );
66 + $store_type = PixCustomifyPlugin()->get_plugin_setting( 'values_store_mod', 'option' );
67 67
68 68 $default_css = __( "/*
69 69 * Welcome to the Custom CSS Editor
70 70 *
@@ -84,9 +84,9 @@
84 84
85 85 /* An example of a Custom CSS Snippet */
86 86 selector {
87 87 color: green;
88 -}", 'customify_txtd' );
88 +}", 'customify' );
89 89
90 90 if ( $store_type === 'option' ) {
91 91 $CSS = get_option( 'live_css_edit' );
92 92 } elseif ( $store_type === 'theme_mod' ) {
@@ -116,16 +116,16 @@
116 116
117 117 $wp_customize->add_section( 'live_css_edit_section', array(
118 118 'priority' => 11,
119 119 'capability' => 'edit_theme_options',
120 - 'title' => __( 'CSS Editor', 'customify_txtd' ),
120 + 'title' => __( 'CSS Editor', 'customify' ),
121 121 ) );
122 122
123 - $saving_type = PixCustomifyPlugin::get_plugin_option( 'values_store_mod', 'option' );
123 + $saving_type = PixCustomifyPlugin()->get_plugin_setting( 'values_store_mod', 'option' );
124 124
125 125 $wp_customize->add_setting( 'live_css_edit', array(
126 126 'type' => $saving_type,
127 - 'label' => __( 'CSS Editor', 'customify_txtd' ),
127 + 'label' => __( 'CSS Editor', 'customify' ),
128 128 'capability' => 'edit_theme_options',
129 129 'transport' => 'postMessage',
130 130 'default' => __( "/*
131 131 * Welcome to the Custom CSS Editor
@@ -146,9 +146,9 @@
146 146
147 147 /* An example of a Custom CSS Snippet */
148 148 selector {
149 149 color: green;
150 -}", 'customify_txtd' )
150 +}", 'customify' )
151 151 ) );
152 152
153 153 $this_control = new Pix_Customize_CSS_Editor_Control(
154 154 $wp_customize,
@@ -153,9 +153,9 @@
153 153 $this_control = new Pix_Customize_CSS_Editor_Control(
154 154 $wp_customize,
155 155 'live_css_edit_control',
156 156 array(
157 - 'label' => __( 'Edit Live Css', 'customify_txtd' ),
157 + 'label' => __( 'Edit Live Css', 'customify' ),
158 158 'section' => 'live_css_edit_section',
159 159 'settings' => 'live_css_edit',
160 160 )
161 161 );
@@ -167,9 +167,9 @@
167 167 if ( ! apply_filters( 'customify_css_live_editor_enabled', true ) ) {
168 168 return;
169 169 }
170 170
171 - $store_type = PixCustomifyPlugin::get_plugin_option( 'values_store_mod', 'option' );
171 + $store_type = PixCustomifyPlugin()->get_plugin_setting( 'values_store_mod', 'option' );
172 172 if ( $store_type === 'option' ) {
173 173 $output = get_option( 'live_css_edit' );
174 174 } elseif ( $store_type === 'theme_mod' ) {
175 175 $output = get_theme_mod( 'live_css_edit' );