plugin:tag
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
plugin:tag [2017-03-29 00:01] – 216.66.188.62 | plugin:tag [2024-01-19 23:43] (current) – [Demo / Screenshots] Aleksandr | ||
---|---|---|---|
Line 6: | Line 6: | ||
email : freaks@dokuwiki.org | email : freaks@dokuwiki.org | ||
type : syntax, action, helper | type : syntax, action, helper | ||
- | lastupdate : 2016-01-16 | + | lastupdate : 2023-10-17 |
- | compatible : Weatherwax, Binky, Ponder Stibbons, Hrun, Detritus, Elenor of Tsort | + | compatible : Weatherwax, Binky, Ponder Stibbons, Hrun, Detritus, Elenor of Tsort, Frusterick Manners, !Greebo, Hogfather, Igor, Jack Jackrum |
depends | depends | ||
conflicts | conflicts | ||
Line 18: | Line 18: | ||
donationurl: | donationurl: | ||
---- | ---- | ||
- | |||
- | :!: The 2013-02-15 release fixed a security issue (XSS vulnerability), | ||
===== Description ===== | ===== Description ===== | ||
- | The Tag [[plugins|Plugin]] lets you assign category tags to wiki pages. | + | The Tag Plugin lets you assign category tags to wiki pages. |
- | **Updating from before 2012-08-24**: | ||
===== Components ===== | ===== Components ===== | ||
==== Tag ==== | ==== Tag ==== | ||
+ | Add a tag to the page | ||
{{tag> | {{tag> | ||
- | | + | |
^ [list of tags] | a space separated list of tags that describe the content of the current page | required | ^ [list of tags] | a space separated list of tags that describe the content of the current page | required | ||
Line 40: | Line 39: | ||
* '' | * '' | ||
* with namespaces: '' | * with namespaces: '' | ||
- | * mutiple | + | * multiple |
+ | * '' | ||
==== Topic ==== | ==== Topic ==== | ||
+ | List all pages with given tags. | ||
{{topic> | {{topic> | ||
Line 50: | Line 50: | ||
^ [flags] | ^ [flags] | ||
- | This displays a list of all pages that contain the given category tag. The list is sorted alphabetically by page ID. You can also prepend the modifiers '' | + | This displays a list of all pages that contain the given category tag. The list is sorted alphabetically by page ID. You can also prepend the modifiers '' |
+ | * If you do not prepend, it acts as a OR. A page is added if it has one of these tags. | ||
+ | * '' | ||
+ | * '' | ||
Example: | Example: | ||
Line 61: | Line 64: | ||
==== Searchtags ==== | ==== Searchtags ==== | ||
+ | Search form for filtering by tag. | ||
| | ||
Line 75: | Line 79: | ||
* '' | * '' | ||
* '' | * '' | ||
+ | * '' | ||
+ | |||
+ | |||
+ | |||
==== Count ==== | ==== Count ==== | ||
+ | Shows a list of tags and its number of occurrences. | ||
- | {{count> | + | {{count> |
- | ^ [tag] | the category | + | ^ [tags] | The tag for which you want to list the occurrence. Multiple tags separated by spaces. |
+ | ^ & | ||
- | This part allows you to display an overview of your current used tags. It prints the tag and the related occurrence (how often is the tag used?) in your wiki. Either you can specify a '' | + | This part allows you to display an overview of your current used tags. It prints the tag and the related occurrence (how often is the tag used) in your wiki. Either you can specify a '' |
Example: | Example: | ||
* '' | * '' | ||
* '' | * '' | ||
- | * '' | + | * '' |
+ | * '' | ||
| | ||
==== Tagpage ==== | ==== Tagpage ==== | ||
+ | Make link to the tag list | ||
| | ||
Line 104: | Line 116: | ||
The plugin can be configured with the DokuWiki configuration manager available in the admin menu. | The plugin can be configured with the DokuWiki configuration manager available in the admin menu. | ||
- | ^ '' | + | ^ '' |
- | ^ '' | + | ^ '' |
- | ^ '' | + | ^ '' |
^ '' | ^ '' | ||
^ '' | ^ '' | ||
Line 117: | Line 129: | ||
===== Demo / Screenshots ===== | ===== Demo / Screenshots ===== | ||
+ | Topic listing: | ||
+ | {{ https:// | ||
- | {{ http://dump.lupo49.de/tmp/dokuwiki/ | + | Tags: |
- | + | {{ https://trello.com/1/cards/64398723319f190ba6cb5235/attachments/64398760e3c8fe34a7786c62/download/ | |
- | {{ http:// | + | |
===== Changes ===== | ===== Changes ===== | ||
Line 161: | Line 174: | ||
* [[http:// | * [[http:// | ||
* [[http:// | * [[http:// | ||
+ | * [[https:// | ||
+ | |||
Line 175: | Line 190: | ||
< | < | ||
{{tag>" | {{tag>" | ||
+ | </ | ||
+ | |||
+ | ==== How to make the tag namespace breadcrumb still work ==== | ||
+ | |||
+ | Let's use one of the example websites. | ||
+ | |||
+ | If you go to https:// | ||
+ | To make your pages inside the tag namespace always go to the tag list, add this to the beginning of your /.htaccess | ||
+ | |||
+ | This also allows you to keep your start page to add there, for example, the list of tags | ||
+ | If your [[config: | ||
+ | |||
+ | < | ||
+ | RewriteCond %{REQUEST_URI} | ||
+ | RewriteRule ^tag.([\-_a-zA-Z0-9\ ]*)$ tag: | ||
</ | </ | ||
Line 181: | Line 211: | ||
This colors the background of the page to red if the keyword ' | This colors the background of the page to red if the keyword ' | ||
- | <code php> | + | < |
function _handle_keywords(& | function _handle_keywords(& | ||
global $ID; | global $ID; | ||
Line 187: | Line 217: | ||
// Fetch tags for the page; stop proceeding when no tags specified | // Fetch tags for the page; stop proceeding when no tags specified | ||
$tags = p_get_metadata($ID, | $tags = p_get_metadata($ID, | ||
- | if(is_null($tags)) | + | if(is_null($tags)) |
// Replace underscores with blanks | // Replace underscores with blanks | ||
Line 194: | Line 224: | ||
$meta[' | $meta[' | ||
+ | // add extra styling | ||
$t = explode(',', | $t = explode(',', | ||
if(in_array(' | if(in_array(' | ||
Line 314: | Line 345: | ||
} | } | ||
</ | </ | ||
+ | |||
==== How to change the word tag and topic to another language ==== | ==== How to change the word tag and topic to another language ==== | ||
> Is it possible to change the word tag used in syntax to something else, like another language < | > Is it possible to change the word tag used in syntax to something else, like another language < | ||
+ | |||
+ | You need to add copy of the existing tag pattern, and modify it to | ||
+ | <code php syntax/ | ||
+ | $this-> | ||
+ | //e.g. Spanish: | ||
+ | $this-> | ||
+ | </ | ||
===== Discussion ===== | ===== Discussion ===== | ||
+ | |||
+ | ==== Pagelist With Alphabetical Headers ==== | ||
+ | |||
+ | Is there a way to group pages by the first letter of their name or header? | ||
+ | |||
+ | Something like the example in this post on the user forums? https:// | ||
+ | > No. | ||
+ | |||
+ | ==== Collapsible outline of all tags ==== | ||
+ | My ideal tag " | ||
+ | --davidtango 2021-03-21 | ||
+ | |||
+ | --- | ||
+ | |||
I want the description under the tag, is it possible to make a line brake or to get the description under the tag? Thx | I want the description under the tag, is it possible to make a line brake or to get the description under the tag? Thx | ||
Line 324: | Line 377: | ||
- | How do I tag a page? Lots of detail about how to display tagged pages, but I cannot find anything about how to tag a page to begin with. | ||
- | |||
- | > You have to type it into the page. Look at the **Components** portion of this page to see what to type. | ||
For __**bugs or feature requests, there is the bug tracker**__ linked here : [[https:// | For __**bugs or feature requests, there is the bug tracker**__ linked here : [[https:// | ||
Line 360: | Line 410: | ||
Same here, get a Nothing was found page. | Same here, get a Nothing was found page. | ||
- | (2017-03-28) | + | (2017-03-28) |
== SEO meta keywords == | == SEO meta keywords == | ||
Line 367: | Line 417: | ||
== Sorting the {{count> | == Sorting the {{count> | ||
Is there any way to sort the output of the %%{{count> | Is there any way to sort the output of the %%{{count> | ||
+ | |||
+ | This can be achieved by editing the '' | ||
== Unorderd List of all tags? == | == Unorderd List of all tags? == | ||
Is there a way to gen an unorderd list of all tags, similar as {{count> | Is there a way to gen an unorderd list of all tags, similar as {{count> | ||
+ | |||
+ | == Filtering the list of Tags? == | ||
+ | Hi, I have attempted to try an solve this but my apologies as I do not know enough about PHP. I use some tags on the site to create dynamic links and I was wondering if there is a way to have the tagsearch have the capability to ignore certain tags. In this case I start the dynamic tags with dw_ and would like to know if possible to filter out all the tags that start with dw_. Thanks for any help! Frank. | ||
+ | |||
+ | == Add " | ||
+ | I need a function to add all the tags under a tag namespace to the tag list.\\ | ||
+ | That is, when I have a ns1:tag1, ns1:tag2, ..., ns1:tagN, I can use < | ||
+ | Now the tag namespace cannot be managed, I hope the basic function can be added.\\ | ||
+ | 2021-6-28 |
plugin/tag.1490738472.txt.gz · Last modified: 2017-03-29 00:01 by 216.66.188.62