====== usersubscriptions Plugin ====== ---- plugin ---- description: Allows connected users to see which pages / namespaces they have subscribed to and to subscribe or unsubscribe in a quick way author : Etienne Meleard email : etienne.meleard@free.fr type : Syntax lastupdate : 2009-09-15 compatible : depends : conflicts : similar : listeabo tags : subscription listing syntax downloadurl: https://trello.com/1/cards/5d503d902dd91087fcb95e97/attachments/5d503ea68b6b6822c2e08515/download/usersubscriptions.zip bugtracker : sourcerepo : donationurl: screenshot_img: ---- ===== Description ===== The Syntax Plugin allows to display the subscription list of the current user. It can display list for a specific namespace, the current namespace or all namespaces. In addition, it provides a quick way to subscribe or unsubscribe. * 2010-09-24: merged some patches (thx to "MR") and fixed caching issue * 2009-09-15: added template for easy styling, fixed some bugs (img paths...) and added regexp based item exclusion (for _template, sidebar...) * 2009-01-27: Added ACL check for quick subscribe dropdown filling * 2009-01-26: inherited subscription display option added, recursive parent subscription check fixed //En, De, Pt, Es and Fr lang files included, translations are welcome...// //**Many thanks to Thomas and Mark for the De lang file, to RC for Pt lang file and to Federico for Es lang file**// ===== Syntax ===== * ''[ns]'' --- base namespace, MUST BE PRESENT IF OTHER OPTIONS ARE USED.\\ Can be either empty or\\ ''.'' for targeting the current namespace,\\ ''*'' for targeting all namespaces or a specific namespace (must be absolute) * ''[r[=[N]]]'' --- recursive option, if only ''r'' or ''r='' are mentioned the maximum depth is infinite, if a number is passed it indicates how much successive namespaces will be explored (ex.: ''r=0'' means only the current namespace, ''r=3'' means 3 levels in depth) * ''[deletelink]'' --- if present a link to unsubscribe is displayed * ''[quicksubscribe]'' --- if present a form is displayed to allow the user to quick-subscribe * ''[displayinheritedsubscriptions]'' --- if present elements that are subscribed because the user subscribed to a parent namespace. ===== Download and Installation ===== Search and install the plugin using the [[plugin:extension|Extension Manager]]. Refer to [[:Plugins]] on how to install plugins manually. * [[https://trello.com/1/cards/5d503d902dd91087fcb95e97/attachments/5d503ea68b6b6822c2e08515/download/usersubscriptions.zip|usersubscriptions.zip]] ==== Translations ==== ===== Screenshot ===== Generated by putting '''' in the page. {{ https://trello.com/1/cards/5d503d902dd91087fcb95e97/attachments/5d503de7b8a7718089016ebe/download/usersubscriptions_screenshot.png?recache }} ===== Discussion ===== ==== 2009-05-01 ==== * "src" values for elements are broken for any site that has a non-default directory structure. For example we have DokuWiki installed to /wiki instead of /. * A similar problem exists for the URL of a background element in the style.css file. > Fixed in new release * If the "action" parameter of the quicksubscribe
element contains a value for id (I'm not sure when it wouldn't), it is ignored when the form is submitted. I added this line between where the and '; > The ID parameter is just useful to stay on the same page, but not needed in request vars, it should work (and does for me) without your fix * For some unknown reason I get an exception in syntax.php @ line 211 complaining that the <...>data/pages/cache directory doesn't exist. One way to fix this is to wrap the 5 lines starting with 211 in a try-catch block. I noticed that I do have a <...>data/pages/_cache directory. Possibly wikiFN() is stripping off valid characters from directory names? > I was unable to reproduce that, but it seems strange (to me at least) that you have a _cache directory in data/pages ==== 2009-06-04 ==== * I fixed the "src" values for just by replacing the /lib/blablabla by ./lib/blablabla in the syntax.php file. > I fixed this bug in last release, used relative path ==== 2009-06-10 ==== * For quicksubscribe it might be a good idea to exclude template ( e.g. __template.txt or _template.txt) and sidebar (e.g. sidebar.txt) pages from beeing listed. \\ \\ It also might be a good idea only to show namespaces and pages a user has the read privilege. > Added a regexp based namespace exclusion capability, have a look in the _getUserSubscriptions method in syntax.php > In the same method there was also a read privilege check from the beginning --- //[[templin@gnuwhv.de|Thomas Templin]], 10. Jun. 2009 11:14 CEST// ==== 2009-08-28 ==== * Download site seems to be gone. I can't get to the files or install the plugin? - writeme -at- ourholm *dot* net > Site is back online, I finally got my internet connection back ... ==== 2009-10-20 ==== * I experienced difficulties both for subscribe and unsubscribe functions. Both don't work. After code investigation, below are suggestions : * For subscribe problem, same as solution explained in discussion 2009-05-01 but I fixed that inside the template * For unsubscribe problem, I have to replace a '?' character by a '&' (coded as &) Here the patch as unified diff --- usersubscriptions.tpl.php.old 2009-10-20 11:02:14.000000000 +0200 +++ usersubscriptions.tpl.php 2009-10-20 11:29:52.000000000 +0200 @@ -45,7 +45,7 @@

- + <?php echo $this->getLang('delete'); ?> @@ -65,6 +65,7 @@ getLang('quick_subscription'); ?> : +