| Server IP : 94.177.215.211 / Your IP : 216.73.216.172 Web Server : nginx/1.26.0 System : Linux mtncompany-wp 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64 User : root ( 0) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system,proc_open,popen,parse_ini_file,show_source,eval MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /var/www/sites/morsiesorsi/wp-content/plugins/js_composer/include/autoload/ |
Upload File : |
<?php
/**
* Autoload hooks for backward compatibility with multisite.
*
* @note we require our autoload files everytime and everywhere after plugin load.
*/
if ( ! defined( 'ABSPATH' ) ) {
die( '-1' );
}
add_action( 'vc_activation_hook', 'vc_bc_multisite_options', 9 );
/**
* Update multisite options.
*
* @param bool $network_wide
*/
function vc_bc_multisite_options( $network_wide ) {
global $current_site;
if ( ! is_multisite() || empty( $current_site ) || ! $network_wide || get_site_option( 'vc_bc_options_called', false ) || get_site_option( 'wpb_js_js_composer_purchase_code', false ) ) {
return;
}
// Now we need to check BC with license keys.
$is_main_blog_activated = get_blog_option( (int) $current_site->id, 'wpb_js_js_composer_purchase_code' );
if ( $is_main_blog_activated ) {
update_site_option( 'wpb_js_js_composer_purchase_code', $is_main_blog_activated );
}
update_site_option( 'vc_bc_options_called', true );
}