shares.php 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  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. * - url is a mandatory option. It is a string representing the share URL. It
  10. * supports 3 different placeholders for custom data. The ~URL~ placeholder
  11. * represents the URL of the system used to share, it is configured by the
  12. * user. The ~LINK~ placeholder represents the link of the shared article.
  13. * The ~TITLE~ placeholder represents the title of the shared article.
  14. * - transform is an array of transformation to apply on links and titles
  15. * - help is a URL to a help page
  16. */
  17. return array(
  18. 'shaarli' => array(
  19. 'url' => '~URL~?post=~LINK~&amp;title=~TITLE~&amp;source=FreshRSS',
  20. 'transform' => array('rawurlencode'),
  21. 'help' => 'http://sebsauvage.net/wiki/doku.php?id=php:shaarli',
  22. 'form' => 'advanced',
  23. ),
  24. 'blogotext' => array(
  25. 'url' => '~URL~/admin/links.php?url=~LINK~',
  26. 'transform' => array(),
  27. 'help' => 'http://lehollandaisvolant.net/blogotext/fr/',
  28. 'form' => 'advanced',
  29. ),
  30. 'wallabag' => array(
  31. 'url' => '~URL~?action=add&amp;url=~LINK~',
  32. 'transform' => array(
  33. 'link' => array('base64_encode'),
  34. 'title' => array(),
  35. ),
  36. 'help' => 'http://www.wallabag.org/',
  37. 'form' => 'advanced',
  38. ),
  39. 'wallabagv2' => array(
  40. 'url' => '~URL~/bookmarklet?url=~LINK~',
  41. 'transform' => array(
  42. 'link' => array('rawurlencode'),
  43. 'title' => array(),
  44. ),
  45. 'help' => 'http://www.wallabag.org/',
  46. 'form' => 'advanced',
  47. ),
  48. 'diaspora' => array(
  49. 'url' => '~URL~/bookmarklet?url=~LINK~&amp;title=~TITLE~',
  50. 'transform' => array('rawurlencode'),
  51. 'help' => 'https://diasporafoundation.org/',
  52. 'form' => 'advanced',
  53. ),
  54. 'movim' => array(
  55. 'url' => '~URL~/?share/~LINK~',
  56. 'transform' => array('rawurlencode', 'urlencode'),
  57. 'help' => 'https://github.com/edhelas/movim',
  58. 'form' => 'advanced',
  59. ),
  60. 'twitter' => array(
  61. 'url' => 'https://twitter.com/share?url=~LINK~&amp;text=~TITLE~',
  62. 'transform' => array('rawurlencode'),
  63. 'form' => 'simple',
  64. ),
  65. 'g+' => array(
  66. 'url' => 'https://plus.google.com/share?url=~LINK~',
  67. 'transform' => array('rawurlencode'),
  68. 'form' => 'simple',
  69. ),
  70. 'facebook' => array(
  71. 'url' => 'https://www.facebook.com/sharer.php?u=~LINK~&amp;t=~TITLE~',
  72. 'transform' => array('rawurlencode'),
  73. 'form' => 'simple',
  74. ),
  75. 'email' => array(
  76. 'url' => 'mailto:?subject=~TITLE~&amp;body=~LINK~',
  77. 'transform' => array('rawurlencode'),
  78. 'form' => 'simple',
  79. ),
  80. 'print' => array(
  81. 'url' => '#',
  82. 'transform' => array(),
  83. 'form' => 'simple',
  84. ),
  85. 'jdh' => array(
  86. 'url' => 'https://www.journalduhacker.net/stories/new?url=~LINK~&title=~TITLE~',
  87. 'transform' => array('rawurlencode'),
  88. 'form' => 'simple',
  89. ),
  90. );