Skip to content

Instantly share code, notes, and snippets.

@timersys
Created August 18, 2014 14:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save timersys/20a8a223e9ff9ef48c82 to your computer and use it in GitHub Desktop.
Save timersys/20a8a223e9ff9ef48c82 to your computer and use it in GitHub Desktop.
My Creed multiple points wiht WSI
add_filter( 'wsi_cred_type', 'mycreed_points_types', 10, 2);
function mycreed_points_types( $cred_type, $wsi_obj_id ){
// default mycreed type
$cred_type = 'mycred_default';
// invitations sent on page with id 2
if( '2' == $wsi_obj_id ) {
$cred_type = 'my_points_type';
}
// invitations sent on page with id 6
if( '6' == $wsi_obj_id ) {
$cred_type = 'my_points_type';
}
return $cred_type;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment