function facebook_install() {
register_hook('post_local_end', 'addon/facebook/facebook.php', 'facebook_post_hook');
register_hook('jot_networks', 'addon/facebook/facebook.php', 'facebook_jot_nets');
- register_hook('plugin_settings', 'addon/facebook/facebook.php', 'facebook_plugin_settings');
+ register_hook('connector_settings', 'addon/facebook/facebook.php', 'facebook_plugin_settings');
register_hook('cron', 'addon/facebook/facebook.php', 'facebook_cron');
register_hook('queue_predeliver', 'addon/facebook/facebook.php', 'fb_queue_hook');
}
function facebook_uninstall() {
unregister_hook('post_local_end', 'addon/facebook/facebook.php', 'facebook_post_hook');
unregister_hook('jot_networks', 'addon/facebook/facebook.php', 'facebook_jot_nets');
+ unregister_hook('connector_settings', 'addon/facebook/facebook.php', 'facebook_plugin_settings');
unregister_hook('plugin_settings', 'addon/facebook/facebook.php', 'facebook_plugin_settings');
unregister_hook('cron', 'addon/facebook/facebook.php', 'facebook_cron');
unregister_hook('queue_predeliver', 'addon/facebook/facebook.php', 'fb_queue_hook');
function statusnet_install() {
// we need some hooks, for the configuration and for sending tweets
- register_hook('plugin_settings', 'addon/statusnet/statusnet.php', 'statusnet_settings');
- register_hook('plugin_settings_post', 'addon/statusnet/statusnet.php', 'statusnet_settings_post');
+ register_hook('connector_settings', 'addon/statusnet/statusnet.php', 'statusnet_settings');
+ register_hook('connector_settings_post', 'addon/statusnet/statusnet.php', 'statusnet_settings_post');
register_hook('post_local_end', 'addon/statusnet/statusnet.php', 'statusnet_post_hook');
register_hook('jot_networks', 'addon/statusnet/statusnet.php', 'statusnet_jot_nets');
logger("installed statusnet");
function statusnet_uninstall() {
+ unregister_hook('connector_settings', 'addon/statusnet/statusnet.php', 'statusnet_settings');
+ unregister_hook('connector_settings_post', 'addon/statusnet/statusnet.php', 'statusnet_settings_post');
unregister_hook('plugin_settings', 'addon/statusnet/statusnet.php', 'statusnet_settings');
unregister_hook('plugin_settings_post', 'addon/statusnet/statusnet.php', 'statusnet_settings_post');
unregister_hook('post_local_end', 'addon/statusnet/statusnet.php', 'statusnet_post_hook');
}
}
}
- goaway($a->get_baseurl().'/settings/addon');
+ goaway($a->get_baseurl().'/settings/connectors');
} else {
if (isset($_POST['statusnet-consumersecret'])) {
// check if we can reach the API of the StatusNet server
notice( t('We could not contact the StatusNet API with the Path you entered.').EOL );
}
}
- goaway($a->get_baseurl().'/settings/addon');
+ goaway($a->get_baseurl().'/settings/connectors');
} else {
if (isset($_POST['statusnet-pin'])) {
// if the user supplied us with a PIN from Twitter, let the magic of OAuth happen
set_pconfig(local_user(),'statusnet', 'oauthsecret', $token['oauth_token_secret']);
set_pconfig(local_user(),'statusnet', 'post', 1);
// reload the Addon Settings page, if we don't do it see Bug #42
- goaway($a->get_baseurl().'/settings/addon');
+ goaway($a->get_baseurl().'/settings/connectors');
} else {
// if no PIN is supplied in the POST variables, the user has changed the setting
// to post a tweet for every new __public__ posting to the wall
function twitter_install() {
// we need some hooks, for the configuration and for sending tweets
- register_hook('plugin_settings', 'addon/twitter/twitter.php', 'twitter_settings');
- register_hook('plugin_settings_post', 'addon/twitter/twitter.php', 'twitter_settings_post');
+ register_hook('connector_settings', 'addon/twitter/twitter.php', 'twitter_settings');
+ register_hook('connector_settings_post', 'addon/twitter/twitter.php', 'twitter_settings_post');
register_hook('post_local_end', 'addon/twitter/twitter.php', 'twitter_post_hook');
register_hook('jot_networks', 'addon/twitter/twitter.php', 'twitter_jot_nets');
logger("installed twitter");
function twitter_uninstall() {
+ unregister_hook('connector_settings', 'addon/twitter/twitter.php', 'twitter_settings');
+ unregister_hook('connector_settings_post', 'addon/twitter/twitter.php', 'twitter_settings_post');
unregister_hook('plugin_settings', 'addon/twitter/twitter.php', 'twitter_settings');
unregister_hook('plugin_settings_post', 'addon/twitter/twitter.php', 'twitter_settings_post');
unregister_hook('post_local_end', 'addon/twitter/twitter.php', 'twitter_post_hook');
set_pconfig(local_user(),'twitter', 'oauthsecret', $token['oauth_token_secret']);
set_pconfig(local_user(),'twitter', 'post', 1);
// reload the Addon Settings page, if we don't do it see Bug #42
- goaway($a->get_baseurl().'/settings/addon');
+ goaway($a->get_baseurl().'/settings/connectors');
} else {
// if no PIN is supplied in the POST variables, the user has changed the setting
// to post a tweet for every new __public__ posting to the wall