When you install a plugin in WordPress, you have to activate each of them, which can be a bit time consuming and irritating to some users. This trick will help you bypass that step with the help of one line of code.

Procedure:

Note: Do take backup of the file before you try this.

01. Place this code in wp-config.php file:

// get already activated plugins
$plugins = get_option('active_plugins');
if($plugins){
$puginsToActiv = array('Plugin1', 'Plugin2', 'Plugin3');
foreach ($puginsTostActiv as $plugin){
if (!in_array($plugin, $plugins)) {
array_push($plugins,$plugin);
update_option('active_plugins',$plugins);
}
}
}


This concludes this simple and useful tutorial. Hope you like it.