<?php
/**
* Name: Random Planet, Empirial Version
- * Description: Sample Friendica plugin/addon. Set a random planet from the Emprire when posting.
+ * Description: Sample Friendica addon. Set a random planet from the Emprire when posting.
* Version: 1.0
* Author: Mike Macgirvin <http://macgirvin.com/profile/mike>
* Author: Tony Baldwin <https://free-haven.org/profile/tony>
/**
*
- * Our demo plugin will attach in three places.
+ * Our demo addon will attach in three places.
* The first is just prior to storing a local post.
*
*/
/**
*
- * Then we'll attach into the plugin settings page, and also the
+ * Then we'll attach into the addon settings page, and also the
* settings post hook so that we can create and update
* user preferences.
*
*/
- Addon::registerHook('plugin_settings', 'addon/planets/planets.php', 'planets_settings');
- Addon::registerHook('plugin_settings_post', 'addon/planets/planets.php', 'planets_settings_post');
+ Addon::registerHook('addon_settings', 'addon/planets/planets.php', 'planets_settings');
+ Addon::registerHook('addon_settings_post', 'addon/planets/planets.php', 'planets_settings_post');
logger("installed planets");
}
*/
Addon::unregisterHook('post_local', 'addon/planets/planets.php', 'planets_post_hook');
- Addon::unregisterHook('plugin_settings', 'addon/planets/planets.php', 'planets_settings');
- Addon::unregisterHook('plugin_settings_post', 'addon/planets/planets.php', 'planets_settings_post');
+ Addon::unregisterHook('addon_settings', 'addon/planets/planets.php', 'planets_settings');
+ Addon::unregisterHook('addon_settings_post', 'addon/planets/planets.php', 'planets_settings_post');
logger("removed planets");
* An item was posted on the local system.
* We are going to look for specific items:
* - A status post by a profile owner
- * - The profile owner must have allowed our plugin
+ * - The profile owner must have allowed our addon
*
*/
/**
*
- * Called from the Plugin Setting form.
+ * Called from the Addon Setting form.
* Add our own settings info to the page.
*
*/
$s .= '<div class="settings-block">';
$s .= '<h3>' . t('Planets Settings') . '</h3>';
$s .= '<div id="planets-enable-wrapper">';
- $s .= '<label id="planets-enable-label" for="planets-checkbox">' . t('Enable Planets Plugin') . '</label>';
+ $s .= '<label id="planets-enable-label" for="planets-checkbox">' . t('Enable Planets Addon') . '</label>';
$s .= '<input id="planets-checkbox" type="checkbox" name="planets" value="1" ' . $checked . '/>';
$s .= '</div><div class="clear"></div></div>';