You could check which options they add (look at the source code) and then simply write a function like this:
/*
Plugin Name: Mother of all plugins
Plugin URI: http://wordpress.org/extend/plugins/
Description: Offers the <code>$all_plugin_options;</code> var to access all predefined plugin options
Author: Franz Josef Kaiser
Author URI: http://say-hello-code.com
Version: 0.1
License: GPL v2 - http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
*/
// Template Tag
function get_all_plugin_options()
{
// First we call the class
$class = new MotherOfAllPlugins;
$data = $class->predefined_plugin_options()
return $data;
}
if ( ! class_exists('MotherOfAllPlugins') )
{
class MotherOfAllPlugins
{
protected $plugin_options;
public function __construct( $plugin_options )
{
// defaults
$default_options = array(
'plugin_a' => array(
'deprecated' => ''
,'name' => 'value'
,'key' => 'value'
)
,'plugin_b' => array(
'deprecated' => ''
,'name' => 'value'
,'key' => 'value'
)
);
// Now overwrite the
$this->plugin_options = array_merge( $default_options, $plugin_options );
add_action( 'init', 'predefined_plugin_options' );
}
function predefined_plugin_options()
{
// Set the flag if we have already done this
// _EDIT #1:_ This sets an option in the wp_options table containing TRUE if your plugin predef options are already present in the DB
if ( !get_option( 'predef_plugins_setup' ) === TRUE )
add_option( 'predef_plugins_setup', TRUE );
if ( !get_option( 'predef_plugins_setup' ) === TRUE )
{
// Add the options for the plugins
foreach ( $plugin_options as $plugin => $options )
{
add_option( $plugin, $options, $options['deprecated'], 'yes' );
}
}
// _EDIT #2:_ return the initial array for use in a global
return $plugin_options
}
} // END Class MotherOfAllPlugins
} // endif;
To get your plugin options inside your theme:
// Now we take the return value & add it into global scope for further useage.
// This way we can access all options easily without a call to the DB.
// You can now access these values from anywhere in your theme.
$all_plugin_options = get_all_plugin_options();
Be careful to really add the options exactly the way the plugins does it. Else stuff won’t work.