Title: Paul
Last modified: August 21, 2016

---

# Paul

 *  Resolved [Bookkus](https://wordpress.org/support/users/bookkus/)
 * (@bookkus)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/paul/)
 * Hi Paul,
 * I was wondering if you do custom programming for the plugin?
    I need it to work
   with Group Reviews. Give achievement points for getting a certain amount of rewards.
   Or can you help me along the road to doing it myself?
 * Let me know.
 * [http://wordpress.org/plugins/achievements/](http://wordpress.org/plugins/achievements/)

Viewing 5 replies - 1 through 5 (of 5 total)

 *  Plugin Author [Paul Wong-Gibbs](https://wordpress.org/support/users/djpaul/)
 * (@djpaul)
 * [12 years, 8 months ago](https://wordpress.org/support/topic/paul/#post-4365462)
 * Hi
 * No, sorry, I can’t take any work, and — FYI — it’s against this forum’s code 
   of contact to try to ask for custom work. Moving swiftly on… 🙂
 * If you know PHP and the basics of WordPress plugin development, I can absolutely
   get you started and tell you what you need to do to get other plugins’ actions
   integrated into Achievements. Let me know.
 *  Thread Starter [Bookkus](https://wordpress.org/support/users/bookkus/)
 * (@bookkus)
 * [12 years, 7 months ago](https://wordpress.org/support/topic/paul/#post-4365490)
 * Sorry about the asking for custom work.
 * I have this code so far, but it is from an earlier developer. I was wondering
   how to hook it in.
 *     ```
       <?php
   
       // create custom plugin settings menu
       add_action('admin_menu', 'j_create_menu');
   
       function achievements_tweaks_events_activate() {
       	// add the new 'action' values for achievements into the achievements table.
       	global $wpdb;
   
       	$achievement_category = 'group_review';
       	$achievement_is_group_action = 0;
       	$achievement_name = 'group_review_add_rating';
       	$achievement_description = 'Achieve once group review reached';
   
       	$wpdb->insert( 'wp_achievements_actions', array( 'category' => $achievement_category, 'is_group_action' => $achievement_is_group_action, 'name' => $achievement_name, 'description' => $achievement_description), array( '%s', '%d', '%s', '%s' ) );
   
       }
   
       function achievements_tweaks_events_deactivate() {
   
       	// remove the actions from the table wp_achievements_actions table
       	global $wpdb;
       	$achievement_category = 'group_review'; // make sure this title is unique to your plug-in
   
       	// remove the actions from the table wp_achievements_actions table
       	$wpdb->query("DELETE FROM wp_achievements_actions WHERE category like '".$achievement_category."'");
   
       	// remove any unlocked achievement references to these actions.
       	// we'el leave these hanging in case the achievement is reactivated.
   
       }
       register_deactivation_hook( __FILE__, 'achievements_tweaks_events_deactivate' );
   
       register_activation_hook( __FILE__, 'achievements_tweaks_events_activate' );
   
       function j_create_menu() {
   
       	//create new top-level menu
       	add_menu_page('J Plugin Settings', 'J Settings', 'administrator', __FILE__, 'j_settings_page','');
   
       	//call register settings function
       	add_action( 'admin_init', 'register_mysettings' );
       }
   
       function register_mysettings() {
       	//register our settings
       	register_setting( 'j-settings-group', 'enable_achievement_on_group' );
       /* 	register_setting( 'j-settings-group', 'some_other_option' ); */
       }
   
       function j_settings_page() {
       	?>
       <div class="wrap">
       <h2>J connection options</h2>
   
       <form method="post" action="options.php">
           <?php settings_fields( 'j-settings-group' ); ?>
           <?php //do_settings( 'j-settings-group' ); ?>
           <table class="form-table">
               <tr valign="top">
               <th scope="row">Enable Achievements</th>
               <td><input type="text" name="enable_achievement_on_group" value="<?php echo get_option('enable_achievement_on_group'); ?>" /></td>
               </tr>
   
           </table>
   
           <?php submit_button(); ?>
   
       </form>
       </div>
       <?php }
   
       /**
        * Implements the group_review_add_rating action for BuddyPress
        *
        * @since 2.0
        */
       function dpa_handle_action_group_review_add_rating() { $func_get_args = func_get_args(); dpa_handle_action( 'group_review_add_rating', $func_get_args ); } ?>
       ```
   
 *  Plugin Author [Paul Wong-Gibbs](https://wordpress.org/support/users/djpaul/)
 * (@djpaul)
 * [12 years, 7 months ago](https://wordpress.org/support/topic/paul/#post-4365491)
 * Ah, that looks like it’s for the old 2.x versions of the plugin. When I get some
   time in the next few days, I’ll pull apart the relevant bits of this, and put
   a quick/untested version up here for you.
 *  Plugin Author [Paul Wong-Gibbs](https://wordpress.org/support/users/djpaul/)
 * (@djpaul)
 * [12 years, 7 months ago](https://wordpress.org/support/topic/paul/#post-4365578)
 * Haven’t gotten to this, probably won’t until after Christmas now. Best to email
   me if you need help with this still.
 *  Plugin Author [Paul Wong-Gibbs](https://wordpress.org/support/users/djpaul/)
 * (@djpaul)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/paul/#post-4365606)
 * Old thread, but look at [http://achievementsapp.com/developers/adding-other-plugins/](http://achievementsapp.com/developers/adding-other-plugins/)
   if you still need help supporting a custom action in the current version of Achievements.

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Paul’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/achievements.svg)
 * [Achievements for WordPress](https://wordpress.org/plugins/achievements/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/achievements/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/achievements/)
 * [Active Topics](https://wordpress.org/support/plugin/achievements/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/achievements/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/achievements/reviews/)

 * 5 replies
 * 2 participants
 * Last reply from: [Paul Wong-Gibbs](https://wordpress.org/support/users/djpaul/)
 * Last activity: [12 years, 5 months ago](https://wordpress.org/support/topic/paul/#post-4365606)
 * Status: resolved