-
Notifications
You must be signed in to change notification settings - Fork 0
/
TagsPluginWebSelector.txt
26 lines (21 loc) · 1.27 KB
/
TagsPluginWebSelector.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
%META:TOPICINFO{author="BaseUserMapping_333" date="1252698596" format="1.1" reprev="1.2" version="1.2"}%
%META:TOPICPARENT{name="TagsPlugin"}%
---++ <nop>TagsPlugin Web Selector
This topic is included by the =tagspluginjquery= template.
By default it presents the user two or more links:
* one link for "all" and
* one link for each web.
The current web is preselected with =tagsplugin_web_active=.
Whenever a tagcloud is requested by the user (by clicking on the selector buttons), the %SYSTEMWEB%.TagsPlugin reads the custom attribute =web= from the html element which is marked with the class =tagsplugin_web_active=.
%X% Make sure, that initially this class is only set on one element.
If you want to customize the "web buttons", this is the right place.
---++ Implementation
<verbatim>
%STARTINCLUDE% <span class='foswikiGrayText'>Webs:</span>
<a href='#' class='tagsplugin_web %IF{"$ TAGSPLUGIN_WEBSELECTOR_DEFAULT='all'" then="tagsplugin_web_active"}%' web='all'>%ICON{filter}% all</a>
%FLEXWEBLIST{
webs="public, -Trash"
format=" <a href='#' class='tagsplugin_web $percntIF{\"$ TAGSPLUGIN_WEBSELECTOR_DEFAULT='$name'\" then=\"tagsplugin_web_active\"}$percnt' web='$name'>$percntICON{filter}$percnt $name</a>"
separator="$n"
}%%STOPINCLUDE%
</verbatim>