Home / RSS Feeds / Activer automatiquement Elementor Pro
Duplicate Snippet

Embed Snippet on Your Site

Activer automatiquement Elementor Pro

add_action('init', function () {
$extensions = [
'elementor/elementor.php',
'elementor-pro/elementor-pro.php'
];
foreach ( $extensions as $extension ) {
if ( !is_plugin_active( $extension ) && file_exists( WP_PLUGIN_DIR . '/' . $extension ) ) {
activate_plugin( $extension );
}
}
});

Code Preview
php
<?php
add_action('init', function () {
    $extensions = [
        'elementor/elementor.php',
        'elementor-pro/elementor-pro.php'
    ];
    foreach ( $extensions as $extension ) {
        if ( !is_plugin_active( $extension ) && file_exists( WP_PLUGIN_DIR . '/' . $extension ) ) {
            activate_plugin( $extension );
        }
    }
});

Comments

Add a Comment