You are here

README.txt in User Relationships 5.2

User Relationship Blocks Module
-------------------------
This module allows users to add blocks for user relationships.

Send comments to Jeff Smick: http://drupal.org/user/107579/contact, or post an issue at
http://drupal.org/project/user_relationships.


Requirements
------------
Drupal 5
User Relationships


Installation
------------
1. Enable User Relationship Blocks in the "Site building -> modules" administration screen.



Developers
------------
This module provides a single hook that passes in identifying information about the block. Depending on the
$op passed in it will expect different information back.

  hook_user_relationship_blocks($op, $block_type, $rtid, $extra);

  $op       | expected return
  -----------------------------------------------------------------------------------------------------------------------------
  display   | A user object. It's a way for developers to display relationship information on non-standard pages. If nothing
            | is sent back the module will check if arg(0) matches "user" or "node" and pull the account information from that.

  
  $block_type   | description
  -----------------------------------------------------------------------------------------------------------------------------
  UR_BLOCK_MY   | the block relates to the currently logged in user
  UR_BLOCK_USER | the block relates to a specified user (normally the author of the current node)
  pending       | pending relationship requests, normally for the currently logged in user
  actions       | relationships and actions between the currently logged in user and normally the author of the current node


  $rtid
  -----------------------------------------------------------------------------------------------------------------------------
  Either UR_BLOCK_ALL_TYPES for any relationship type or an rtid corresponding to a specific relationship type
  I use "normally" because those values can be overridden by the hook


  $extra
  -----------------------------------------------------------------------------------------------------------------------------
  Any extra data about the block. Currently this is only used to specify which side of a one-way relationship should be shown.
  It will be either "you_to_them" or "them_to_you" where "you" means the currently logged in user and "them" means the specified
  user.



Credits
-------
Originally Written by JB Christy.
Refactored by Jeff Smick.
Written originally for and financially supported by OurChart Inc. (http://www.ourchart.com)
Thanks to the BuddyList module team for their inspiration

File

plugins/user_relationship_blocks/README.txt
View source
  1. User Relationship Blocks Module
  2. -------------------------
  3. This module allows users to add blocks for user relationships.
  4. Send comments to Jeff Smick: http://drupal.org/user/107579/contact, or post an issue at
  5. http://drupal.org/project/user_relationships.
  6. Requirements
  7. ------------
  8. Drupal 5
  9. User Relationships
  10. Installation
  11. ------------
  12. 1. Enable User Relationship Blocks in the "Site building -> modules" administration screen.
  13. Developers
  14. ------------
  15. This module provides a single hook that passes in identifying information about the block. Depending on the
  16. $op passed in it will expect different information back.
  17. hook_user_relationship_blocks($op, $block_type, $rtid, $extra);
  18. $op | expected return
  19. -----------------------------------------------------------------------------------------------------------------------------
  20. display | A user object. It's a way for developers to display relationship information on non-standard pages. If nothing
  21. | is sent back the module will check if arg(0) matches "user" or "node" and pull the account information from that.
  22. $block_type | description
  23. -----------------------------------------------------------------------------------------------------------------------------
  24. UR_BLOCK_MY | the block relates to the currently logged in user
  25. UR_BLOCK_USER | the block relates to a specified user (normally the author of the current node)
  26. pending | pending relationship requests, normally for the currently logged in user
  27. actions | relationships and actions between the currently logged in user and normally the author of the current node
  28. $rtid
  29. -----------------------------------------------------------------------------------------------------------------------------
  30. Either UR_BLOCK_ALL_TYPES for any relationship type or an rtid corresponding to a specific relationship type
  31. I use "normally" because those values can be overridden by the hook
  32. $extra
  33. -----------------------------------------------------------------------------------------------------------------------------
  34. Any extra data about the block. Currently this is only used to specify which side of a one-way relationship should be shown.
  35. It will be either "you_to_them" or "them_to_you" where "you" means the currently logged in user and "them" means the specified
  36. user.
  37. Credits
  38. -------
  39. Originally Written by JB Christy.
  40. Refactored by Jeff Smick.
  41. Written originally for and financially supported by OurChart Inc. (http://www.ourchart.com)
  42. Thanks to the BuddyList module team for their inspiration