File tree 2 files changed +13
-6
lines changed
2 files changed +13
-6
lines changed Original file line number Diff line number Diff line change 1
- var item = document . getElementById ( 'jsDisabled' ) ;
2
- if ( item . style . display === "block" || ! item . style . display ) {
3
- item . style . display = 'none' ;
4
- }
1
+ /*
2
+ * Plugin JS
3
+ * */
Original file line number Diff line number Diff line change @@ -84,7 +84,7 @@ public function __construct() {
84
84
*
85
85
*/
86
86
public function add_plugin_js () {
87
- wp_enqueue_script ('wp-js-detect-js ' , plugins_url ('js/plugin.js ' , __FILE__ ));
87
+ // wp_enqueue_script('wp-js-detect-js', plugins_url('js/plugin.js', __FILE__));
88
88
}
89
89
90
90
/**
@@ -304,7 +304,15 @@ class="button button-primary button-large">
304
304
*
305
305
*/
306
306
public function wp_non_js_notification () {
307
- echo '<div id="jsDisabled"><p> ' . get_option ('wp_non_js_notification_text ' ) . '</p></div> ' ;
307
+ ?>
308
+ <div id="jsDisabled"><p><?php echo get_option ('wp_non_js_notification_text ' ); ?> </p></div>
309
+ <script>
310
+ var item = document.getElementById('jsDisabled');
311
+ if (item.style.display === "block" || !item.style.display) {
312
+ item.style.display = 'none';
313
+ }
314
+ </script>
315
+ <?php
308
316
309
317
}
310
318
You can’t perform that action at this time.
0 commit comments