Load Plugin First

function load_plugin_first(){
$wp_path_to_this_file = preg_replace('/(.*)plugins/(.*)$/', WP_PLUGIN_DIR."/$2", __FILE__);
$this_plugin = plugin_basename(trim($wp_path_to_this_file));
$active_plugins = get_option('active_plugins');
$this_plugin_key = array_search($this_plugin, $active_plugins);
if($this_plugin_key){
array_splice($active_plugins,$this_plugin_key,1);
array_unshift($active_plugins,$this_plugin);
update_option('active_plugins',$active_plugins);
}
}
add_action('activated_plugin','load_plugin_first');