WordPress Multisite: Programmatically Activate / Deactivate a Plugin of a Specific Blog

Use a combination of switch_to_blog(), activate_plugins(), and deactivate_plugins(). You can put this in functions.php, but you’ll want to remove it once it runs: // hook to admin init add_action(‘admin_init’, ‘wpse_swap_plugins’); function wpse_swap_plugins() { // set blog ID per your needs $blog_id = 3; // switch to the site where you want to activate/deactivate plugins switch_to_blog($blog_id); … Read more

WordPress self hosted site asking to login again when used www

Each subdomain requires separate authentication. Although you can leave your server set to allow both the “www.example.net” subdomain and the “root” domain “example.net”, you’ll run into issues both with authentication and with SEO, because Google also sees “www.example.net” as a different URL than “example.net”. It’s best practice to decide which version you prefer, then set … Read more

Display Different Content For Different Countries?

Since you will have same content for about and product detail page irrespective to its translated version. So, obviously you might face seo penalty. As recently, Google algorithm has clarified a clear cut instructions for ecommerce websites that they can’t use different pages for different languages or countries. So, for your case, I would suggest … Read more

Being Forced To Use Sub-Domains on Multisite

You should just start with a new install and import the existing site into the new install. Starting with an existing install triggers that warning but if you start fresh you can setup the subfolder structure. You can add this to functions.php to allow a subfolder install in multisite: add_filter( ‘allow_subdirectory_install’, create_function( ”, ‘return true;’ … Read more