• Resolved leisegang

    (@leisegang)


    How do i activate only 1 module of the jetpack plugin sitewide on mu multisite install?

    i tried this:
    add_option( 'jetpack_active_modules', 'a:2:{i:0;s:10:"vaultpress";i:1;s:10:"custom-css";}', '', 'yes' );

    but that didnt work. Any help on solving this?

Viewing 2 replies - 1 through 2 (of 2 total)
  • There’s a method in the Jetpack class called activate_module(). I’ve been trying to use it to do something similar.

    I’ve got this:

    Jetpack::activate_module('carousel');
    Jetpack::activate_module('comments');
    Jetpack::activate_module('tiled-gallery');
    Jetpack::activate_module('enhanced-distribution');

    For some reason it only activated the carousel module. Not sure where to go from here. I’ve hooked it to after_setup_theme in my tests but will play around with some other hooks.

    I’m back. Whatever wasn’t work for me seems to be fixed now. Here’s a gist of every module ready to be activated/deactivated. Hope this is useful.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Jetpack activate module’ is closed to new replies.