shares.php 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198
  1. <?php
  2. /*
  3. * This is a configuration file. You shouldn’t modify it unless you know what
  4. * you are doing. If you want to add a share type, this is where you need to do
  5. * it.
  6. *
  7. * For each share there is different configuration options. Here is the description
  8. * of those options:
  9. * - 'deprecated' (optional) is a boolean. Default: 'false'.
  10. * 'true', if the sharing service is planned to remove in the future.
  11. * Add more information into the documentation center.
  12. * - 'url' is a mandatory option. It is a string representing the share URL. It
  13. * supports 4 different placeholders for custom data. The ~URL~ placeholder
  14. * represents the URL of the system used to share, it is configured by the
  15. * user. The ~LINK~ placeholder represents the link of the shared article.
  16. * The ~TITLE~ placeholder represents the title of the shared article. The
  17. * ~ID~ placeholder represents the id of the shared article (only useful
  18. * for internal use)
  19. * - 'transform' is an array of transformation to apply on links and titles
  20. * - 'help' is a URL to a help page (mandatory for form = 'advanced')
  21. * - 'form' is the type of form to display during configuration. It’s either
  22. * 'simple' or 'advanced'. 'simple' is used when only the name is configurable,
  23. * 'advanced' is used when the name and the location are configurable.
  24. * - 'method' is the HTTP method (POST or GET) used to share a link.
  25. */
  26. return array(
  27. 'blogotext' => array(
  28. 'deprecated' => true,
  29. 'url' => '~URL~/admin/links.php?url=~LINK~',
  30. 'transform' => array(),
  31. 'help' => 'http://lehollandaisvolant.net/blogotext/fr/',
  32. 'form' => 'advanced',
  33. 'method' => 'GET',
  34. ),
  35. 'clipboard' => array(
  36. 'HTMLtag' => 'button',
  37. 'url' => '~LINK~',
  38. 'transform' => array(),
  39. 'form' => 'simple',
  40. 'method' => 'GET',
  41. ),
  42. 'diaspora' => array(
  43. 'url' => '~URL~/bookmarklet?url=~LINK~&amp;title=~TITLE~',
  44. 'transform' => array('rawurlencode'),
  45. 'help' => 'https://diasporafoundation.org/',
  46. 'form' => 'advanced',
  47. 'method' => 'GET',
  48. ),
  49. 'email' => array(
  50. 'url' => 'mailto:?subject=~TITLE~&amp;body=~LINK~',
  51. 'transform' => array('rawurlencode'),
  52. 'form' => 'simple',
  53. 'method' => 'GET',
  54. ),
  55. 'facebook' => array(
  56. 'url' => 'https://www.facebook.com/sharer.php?u=~LINK~&amp;t=~TITLE~',
  57. 'transform' => array('rawurlencode'),
  58. 'form' => 'simple',
  59. 'method' => 'GET',
  60. ),
  61. 'gnusocial' => array(
  62. 'url' => '~URL~/notice/new?content=~TITLE~%20~LINK~',
  63. 'transform' => array('urlencode'),
  64. 'help' => 'https://gnu.io/social/',
  65. 'form' => 'advanced',
  66. 'method' => 'GET',
  67. ),
  68. 'jdh' => array(
  69. 'url' => 'https://www.journalduhacker.net/stories/new?url=~LINK~&title=~TITLE~',
  70. 'transform' => array('rawurlencode'),
  71. 'form' => 'simple',
  72. 'method' => 'GET',
  73. ),
  74. 'Known' => array(
  75. 'url' => '~URL~/share?share_url=~LINK~&share_title=~TITLE~',
  76. 'transform' => array('rawurlencode'),
  77. 'help' => 'https://withknown.com/',
  78. 'form' => 'advanced',
  79. 'method' => 'GET',
  80. ),
  81. 'lemmy' => array(
  82. 'url' => '~URL~/create_post?url=~LINK~&name=~TITLE~',
  83. 'transform' => array('rawurlencode'),
  84. 'help' => 'https://join-lemmy.org/',
  85. 'form' => 'advanced',
  86. 'method' => 'GET',
  87. ),
  88. 'linkedin' => array(
  89. 'url' => 'https://www.linkedin.com/shareArticle?url=~LINK~&amp;title=~TITLE~&amp;source=FreshRSS',
  90. 'transform' => array('rawurlencode'),
  91. 'form' => 'simple',
  92. 'method' => 'GET',
  93. ),
  94. 'mastodon' => array(
  95. 'url' => '~URL~/share?title=~TITLE~&url=~LINK~',
  96. 'transform' => array('rawurlencode'),
  97. 'help' => 'https://joinmastodon.org/',
  98. 'form' => 'advanced',
  99. 'method' => 'GET',
  100. ),
  101. 'movim' => array(
  102. 'url' => '~URL~/?share/~LINK~',
  103. 'transform' => array('urlencode'),
  104. 'help' => 'https://movim.eu/',
  105. 'form' => 'advanced',
  106. 'method' => 'GET',
  107. ),
  108. 'pinboard' => array(
  109. 'url' => 'https://pinboard.in/add?next=same&amp;url=~LINK~&amp;title=~TITLE~',
  110. 'transform' => array('urlencode'),
  111. 'help' => 'https://pinboard.in/api/',
  112. 'form' => 'simple',
  113. 'method' => 'GET',
  114. ),
  115. 'pinterest' => array(
  116. 'url' => 'https://pinterest.com/pin/create/button/?url=~LINK~',
  117. 'transform' => array('rawurlencode'),
  118. 'help' => 'https://pinterest.com/',
  119. 'form' => 'simple',
  120. 'method' => 'GET',
  121. ),
  122. 'pocket' => array(
  123. 'url' => 'https://getpocket.com/save?url=~LINK~&amp;title=~TITLE~',
  124. 'transform' => array('rawurlencode'),
  125. 'form' => 'simple',
  126. 'method' => 'GET',
  127. ),
  128. 'print' => array(
  129. 'HTMLtag' => 'button',
  130. 'url' => '#',
  131. 'transform' => array(),
  132. 'form' => 'simple',
  133. 'method' => 'GET',
  134. ),
  135. 'raindrop' => array(
  136. 'url' => 'https://app.raindrop.io/add?link=~LINK~&title=~TITLE~',
  137. 'transform' => array('rawurlencode'),
  138. 'form' => 'simple',
  139. 'method' => 'GET',
  140. ),
  141. 'reddit' => array(
  142. 'url' => 'https://www.reddit.com/submit?url=~LINK~',
  143. 'transform' => array('rawurlencode'),
  144. 'help' => 'https://www.reddit.com/wiki/submitting?v=c2ae883a-04b9-11e4-a68c-12313b01a1fc',
  145. 'form' => 'simple',
  146. 'method' => 'GET',
  147. ),
  148. 'shaarli' => array(
  149. 'url' => '~URL~?post=~LINK~&amp;title=~TITLE~&amp;source=FreshRSS',
  150. 'transform' => array('rawurlencode'),
  151. 'help' => 'http://sebsauvage.net/wiki/doku.php?id=php:shaarli',
  152. 'form' => 'advanced',
  153. 'method' => 'GET',
  154. ),
  155. 'twitter' => array(
  156. 'url' => 'https://twitter.com/share?url=~LINK~&amp;text=~TITLE~',
  157. 'transform' => array('rawurlencode'),
  158. 'form' => 'simple',
  159. 'method' => 'GET',
  160. ),
  161. 'wallabag' => array(
  162. 'url' => '~URL~?action=add&amp;url=~LINK~',
  163. 'transform' => array('rawurlencode'),
  164. 'help' => 'http://www.wallabag.org/',
  165. 'form' => 'advanced',
  166. 'method' => 'GET',
  167. ),
  168. 'wallabagv2' => array(
  169. 'url' => '~URL~/bookmarklet?url=~LINK~',
  170. 'transform' => array('rawurlencode'),
  171. 'help' => 'http://www.wallabag.org/',
  172. 'form' => 'advanced',
  173. 'method' => 'GET',
  174. ),
  175. 'web-sharing-api' => array(
  176. 'HTMLtag' => 'button',
  177. 'url' => '~LINK~',
  178. 'transform' => array(),
  179. 'form' => 'simple',
  180. 'method' => 'GET',
  181. ),
  182. 'whatsapp' => array(
  183. 'url' => 'https://wa.me/?text=~TITLE~ | ~LINK~',
  184. 'transform' => array('rawurlencode'),
  185. 'help' => 'https://faq.whatsapp.com/iphone/how-to-link-to-whatsapp-from-a-different-app/?lang=en',
  186. 'form' => 'simple',
  187. 'method' => 'GET',
  188. ),
  189. 'xing' => array(
  190. 'url' => 'https://www.xing.com/spi/shares/new?url=~LINK~',
  191. 'transform' => array('rawurlencode'),
  192. 'help' => 'https://dev.xing.com/plugins/share_button/docs',
  193. 'form' => 'simple',
  194. 'method' => 'GET',
  195. ),
  196. );