Advertisement
fauzanjeg

Fix Bootstrap JS and Meta Header Issue with WordPress Download Manager Plugin

Aug 19th, 2021 (edited)
162
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.61 KB | None | 0 0
  1. /* Fix Bootstrap JS and Meta Header Issue with WordPress Download Manager Plugin */
  2. if ( in_array( 'download-manager/download-manager.php' , apply_filters( 'active_plugins', get_option( 'active_plugins' ) ) ) ) {
  3.     if ( is_admin() && $_GET['post_type'] == 'wpdmpro') {
  4.         add_action( 'admin_enqueue_scripts','deregister_bootstrap_script_jnews_essential', 100 );
  5.         function deregister_bootstrap_script_jnews_essential() {
  6.             wp_deregister_script( 'bootstrap' );
  7.         }
  8.     }
  9.     if ( isset( $_GET['template_preview'] ) ) {
  10.         remove_action( 'wp_head', array( JNews_Meta_Header::getInstance(), 'generate_social_meta' ), 1 );
  11.     }
  12. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement