Fix: Divi updates

This commit is contained in:
ruben- 2017-01-04 21:03:57 +01:00
parent cfc06af573
commit 3c8f69955d
3 changed files with 40 additions and 35 deletions

View file

@ -779,33 +779,32 @@ class MainWP_Child {
}
}
function admin_head() {
if (isset($_GET['page']) && $_GET['page'] == 'mainwp_child_tab') {
?>
<style type="text/css">
.mainwp-postbox-actions-top {
padding: 10px;
clear: both;
border-bottom: 1px solid #ddd;
background: #f5f5f5;
}
h3.mainwp_box_title {
font-family: "Open Sans",sans-serif;
font-size: 14px;
font-weight: 600;
line-height: 1.4;
margin: 0;
padding: 8px 12px;
border-bottom: 1px solid #eee;
}
.mainwp-child-setting-tab.connection-detail .postbox .inside{
margin: 0;
padding: 0;
}
</style>
<?php
}
function admin_head() {
if (isset($_GET['page']) && $_GET['page'] == 'mainwp_child_tab') {
?>
<style type="text/css">
.mainwp-postbox-actions-top {
padding: 10px;
clear: both;
border-bottom: 1px solid #ddd;
background: #f5f5f5;
}
h3.mainwp_box_title {
font-family: "Open Sans",sans-serif;
font-size: 14px;
font-weight: 600;
line-height: 1.4;
margin: 0;
padding: 8px 12px;
border-bottom: 1px solid #eee;
}
.mainwp-child-setting-tab.connection-detail .postbox .inside{
margin: 0;
padding: 0;
}
</style>
<?php
}
}
function settings() {
if ( isset( $_POST['submit'] ) && isset( $_POST['nonce'] ) && wp_verify_nonce( $_POST['nonce'], 'child-settings' ) ) {
@ -4212,13 +4211,13 @@ class MainWP_Child {
foreach ( $plugins as $idx => $plugin ) {
if ( $plugin !== $this->plugin_slug ) {
if ( isset( $all_plugins[ $plugin ] ) ) {
if (is_plugin_active($plugin)) {
$thePlugin = get_plugin_data( $plugin );
if ( null !== $thePlugin && '' !== $thePlugin ) {
deactivate_plugins( $plugin );
}
}
$tmp['plugin'] = $plugin;
if (is_plugin_active($plugin)) {
$thePlugin = get_plugin_data( $plugin );
if ( null !== $thePlugin && '' !== $thePlugin ) {
deactivate_plugins( $plugin );
}
}
$tmp['plugin'] = $plugin;
if ( true === $pluginUpgrader->delete_old_plugin( null, null, null, $tmp ) ) {
$args = array( 'action' => 'delete', 'Name' => $all_plugins[ $plugin ]['Name'] );
do_action( 'mainwp_child_plugin_action', $args );
@ -5159,5 +5158,9 @@ class MainWP_Child {
if ( file_exists( ABSPATH . '/wp-admin/includes/screen.php' ) ) {
include_once( ABSPATH . '/wp-admin/includes/screen.php' );
}
if ( function_exists( 'et_register_updates_component' ) ) {
et_register_updates_component();
}
}
}

View file

@ -21,6 +21,8 @@ class MainWP_Debug {
$_POST['excludenonwp'] = '1';
$_POST['ext'] = 'tar.gz';
print_r( $mainwpChild->backup( false ) );
} else if ( 'test' == $_GET['mainwpdebug'] ) {
print_r( get_included_files() );
} else {
print_r( $mainwpChild->getSiteStats( array(), false ) );
}

View file

@ -6,7 +6,7 @@
Author: MainWP
Author URI: https://mainwp.com
Text Domain: mainwp-child
Version: 3.2.5
Version: 3.2.6-beta
*/
if ( ( isset( $_REQUEST['heatmap'] ) && '1' === $_REQUEST['heatmap'] ) || ( isset( $_REQUEST['mainwpsignature'] ) && ( ! empty( $_REQUEST['mainwpsignature'] ) ) ) ) {
header( 'X-Frame-Options: ALLOWALL' );