You are here

README.txt in Share Message 7

Same filename and directory in other branches
  1. 8 README.txt
PROJECT
-------
http://drupal.org/project/sharemessage


INSTALLATION
------------
1. Download and extract the module to your sites/all/modules/contrib folder.
2. Enable the module on the Drupal Modules page (admin/modules) or using
   $ drush en


HOW TO ADD SHARING WIDGETS
--------------------------
1. Go to admin/config/services/sharemessage/settings and configure your default
   sharing options. Available options are documented in detail in the section
   "SETTINGS" below.
2. Open the "list" tab and click on "Add sharemessage". Enter the values you
   want to be shared, note that you can use available tokens in order to make
   sharemessages display dynamic content.
3. If you don't want to use the default settings you configured on the settings
   page before, you can override those by checking "Override default settings".
4. Check the "Provide a block" setting.
5. Go to admin/structure/block and configure look for a block that has the name
   of your sharemessage. Use the block settings to control where your share
   message is shown. (Mind the used tokens!).

Alternatively you can use an entityreference field on any node/entity with
display format "Rendered entity" to display sharemessages on within nodes and
fieldable entities.


ENFORCE OVERRIDING SHARE MESSAGES
---------------------------------
It is possible to enforce overriding of certain sharemessages if two sharemes-
sages point to the same URL.
This may be useful for example if you have a share message on a product page and
one on the checkout complete, while both point on the product page, you will
want to display another sharemessage in case the user shares the checkout
complete message.

To accomplish this enforcement of the override, you can just enable the option
"Enforce the usage of this share message on the page it points to" on the share-
message that is displayed on the checkout page.

Be careful if your site uses the querystring "?smid=" somewhere in another con-
text, this may lead to unexpected effects/conflicts. In that case, you can
disable this feature with a global setting.


OPTIONS
-------
- AddThis Profile ID:
  Optional. Enter your addthis profile ID in order to be able to track your
  shares on your addthis account.

- Default visible services:
  Determines which service buttons will be displayed on a share widget. You can
  override this per sharemessage.
 
- Show additional services button:
  If checked, a button, which displays a list of additional services in a popup,
  will be displayed.
 
- Show Addthis counter:
  Adds a share counter that counts all shares and displays the amount of shares
  on a certain page.
 
- Default icon style:
  The size of the share buttons in pixel.

- Use local service definitions file:
  Enable this if your server is located behind some firewall that is blocking
  access to http://cache.addthiscdn.com/services/v1/sharing.en.json and the
  services select field is empty.


EXPORT/IMPORT
-------------
Using entities EntityAPIControllerExportable class, sharemessages are fully
export-/importable. In order to export a sharemessage open the list
(admin/config/services/sharemessage) and use the "export" operation. Importing
can be done by following the "Import share message" link on the same page. Just
paste your exported sharemessage code and import it.


VIEW MODES
----------
Share Message uses view modes to control OG tags and attributes, the following
view modes are provided:

 - "Share links with OG tags and AddThis attributes": Both OG tags and the
   AddThis attributes get rendered (this is the default and recommended setting)

 - "Only OG tags": Renders only OG tags, not displaying any share link. This
   is useful if you have a share link that points to another page where you
   don't want any share link to appear

 - "Share links with OG tags only": Display the share links and OG tags but
   without the AddThis attributes on the share links container

 - "Share links with AddThis attributes only": Renders No OG tags on the page

Note on backwards compatibility:
Previously, the output was only partially controlled through view modes, and
attributes were not added by default, only if multiple share messages were
displayed on a page. A special flag "_force_attributes" existed, that modules
could set through hook_sharemessage_token_context_alter(). As this behavior
is now the default, the flag was removed as share widgets now always work as if
that flag was set.

TESTING SHARES ON FACEBOOK
-------------
In order to test your shares on facebook, you can share your nodes or pages the
usual way, by clicking on the like button. This has the huge disadvantage, that
facebook may cache your share requests of the same page. To avoid this annoying
issue, use facebooks debugger tool: http://developers.facebook.com/tools/debug.


LOCAL SERVICES DEFINITION
-------------
When using the option "Use local service definitions file", the available
services might be outdated. If you see that they are outdated the services
definitions file, that is shipped with the module, has to be updated. Please
create a new issue for that at https://drupal.org/project/issues/sharemessage .


CREDITS
-------------
This module was developed and is maintained by MD Systems (by Miro Dietiker,
Berdir, s_leu). The Development has been sponsored by Kampaweb GmbH
http://kampaweb.ch/ and MD Systems http://www.md-systems.ch.

File

README.txt
View source
  1. PROJECT
  2. -------
  3. http://drupal.org/project/sharemessage
  4. INSTALLATION
  5. ------------
  6. 1. Download and extract the module to your sites/all/modules/contrib folder.
  7. 2. Enable the module on the Drupal Modules page (admin/modules) or using
  8. $ drush en
  9. HOW TO ADD SHARING WIDGETS
  10. --------------------------
  11. 1. Go to admin/config/services/sharemessage/settings and configure your default
  12. sharing options. Available options are documented in detail in the section
  13. "SETTINGS" below.
  14. 2. Open the "list" tab and click on "Add sharemessage". Enter the values you
  15. want to be shared, note that you can use available tokens in order to make
  16. sharemessages display dynamic content.
  17. 3. If you don't want to use the default settings you configured on the settings
  18. page before, you can override those by checking "Override default settings".
  19. 4. Check the "Provide a block" setting.
  20. 5. Go to admin/structure/block and configure look for a block that has the name
  21. of your sharemessage. Use the block settings to control where your share
  22. message is shown. (Mind the used tokens!).
  23. Alternatively you can use an entityreference field on any node/entity with
  24. display format "Rendered entity" to display sharemessages on within nodes and
  25. fieldable entities.
  26. ENFORCE OVERRIDING SHARE MESSAGES
  27. ---------------------------------
  28. It is possible to enforce overriding of certain sharemessages if two sharemes-
  29. sages point to the same URL.
  30. This may be useful for example if you have a share message on a product page and
  31. one on the checkout complete, while both point on the product page, you will
  32. want to display another sharemessage in case the user shares the checkout
  33. complete message.
  34. To accomplish this enforcement of the override, you can just enable the option
  35. "Enforce the usage of this share message on the page it points to" on the share-
  36. message that is displayed on the checkout page.
  37. Be careful if your site uses the querystring "?smid=" somewhere in another con-
  38. text, this may lead to unexpected effects/conflicts. In that case, you can
  39. disable this feature with a global setting.
  40. OPTIONS
  41. -------
  42. - AddThis Profile ID:
  43. Optional. Enter your addthis profile ID in order to be able to track your
  44. shares on your addthis account.
  45. - Default visible services:
  46. Determines which service buttons will be displayed on a share widget. You can
  47. override this per sharemessage.
  48. - Show additional services button:
  49. If checked, a button, which displays a list of additional services in a popup,
  50. will be displayed.
  51. - Show Addthis counter:
  52. Adds a share counter that counts all shares and displays the amount of shares
  53. on a certain page.
  54. - Default icon style:
  55. The size of the share buttons in pixel.
  56. - Use local service definitions file:
  57. Enable this if your server is located behind some firewall that is blocking
  58. access to http://cache.addthiscdn.com/services/v1/sharing.en.json and the
  59. services select field is empty.
  60. EXPORT/IMPORT
  61. -------------
  62. Using entities EntityAPIControllerExportable class, sharemessages are fully
  63. export-/importable. In order to export a sharemessage open the list
  64. (admin/config/services/sharemessage) and use the "export" operation. Importing
  65. can be done by following the "Import share message" link on the same page. Just
  66. paste your exported sharemessage code and import it.
  67. VIEW MODES
  68. ----------
  69. Share Message uses view modes to control OG tags and attributes, the following
  70. view modes are provided:
  71. - "Share links with OG tags and AddThis attributes": Both OG tags and the
  72. AddThis attributes get rendered (this is the default and recommended setting)
  73. - "Only OG tags": Renders only OG tags, not displaying any share link. This
  74. is useful if you have a share link that points to another page where you
  75. don't want any share link to appear
  76. - "Share links with OG tags only": Display the share links and OG tags but
  77. without the AddThis attributes on the share links container
  78. - "Share links with AddThis attributes only": Renders No OG tags on the page
  79. Note on backwards compatibility:
  80. Previously, the output was only partially controlled through view modes, and
  81. attributes were not added by default, only if multiple share messages were
  82. displayed on a page. A special flag "_force_attributes" existed, that modules
  83. could set through hook_sharemessage_token_context_alter(). As this behavior
  84. is now the default, the flag was removed as share widgets now always work as if
  85. that flag was set.
  86. TESTING SHARES ON FACEBOOK
  87. -------------
  88. In order to test your shares on facebook, you can share your nodes or pages the
  89. usual way, by clicking on the like button. This has the huge disadvantage, that
  90. facebook may cache your share requests of the same page. To avoid this annoying
  91. issue, use facebooks debugger tool: http://developers.facebook.com/tools/debug.
  92. LOCAL SERVICES DEFINITION
  93. -------------
  94. When using the option "Use local service definitions file", the available
  95. services might be outdated. If you see that they are outdated the services
  96. definitions file, that is shipped with the module, has to be updated. Please
  97. create a new issue for that at https://drupal.org/project/issues/sharemessage .
  98. CREDITS
  99. -------------
  100. This module was developed and is maintained by MD Systems (by Miro Dietiker,
  101. Berdir, s_leu). The Development has been sponsored by Kampaweb GmbH
  102. http://kampaweb.ch/ and MD Systems http://www.md-systems.ch.