Skip to content

Instantly share code, notes, and snippets.

@glaubersilva
Last active April 10, 2020 17:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save glaubersilva/c8c7c8882b5416bfc90ec94b991a14ec to your computer and use it in GitHub Desktop.
Save glaubersilva/c8c7c8882b5416bfc90ec94b991a14ec to your computer and use it in GitHub Desktop.
<?php
/**
* Plugin Name: [Forminator] Resolves Conflicts With Vs Netflix Theme
* Plugin URI: https://premium.wpmudev.org/
* Description: This plugin resolves conflicts between the Forminator plugin and the Vs Netflix theme.
* Author: Glauber Silva @ WPMUDEV
* Author URI: https://premium.wpmudev.org/
* Task: 0/11289012348292/1170766639260478
* License: GPLv2 or later
*
* @package Forminator_Resolves_Conflicts_With_Vs_Netflix_Theme
*/
defined( 'ABSPATH' ) || exit;
/**
* Removes the styles of the Vs Netflix theme if the current page is a Forminator page.
*/
function wpmudev_dequeue_style_from_vs_netflix() {
if ( isset( $_GET['page'] ) && strpos( $_GET['page'], 'forminator' ) !== false ) { // phpcs:ignore
wp_dequeue_style( 'wpvs-theme-global-admin-css' );
}
}
add_filter( 'admin_enqueue_scripts', 'wpmudev_dequeue_style_from_vs_netflix', PHP_INT_MAX );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment