Knarf
Knarf

Reputation: 2156

How to search only for "tag's" in mediawiki, not whole text

I have a mediaWiki and the users are requesting the following feature :

They want to add keywords/tags to articles so people can search for these keywords.

But they they also want that the search engine ONLY searches for these keywords/tags. And not for text in the article itself.

Upvotes: 2

Views: 362

Answers (2)

Tgr
Tgr

Reputation: 28160

Tags are called categories in MediaWiki. Search support is not great but with the CirrusSearch extension you can use the incategory: keyword to filter search results to the given categories.

Upvotes: 2

Divide by Zero
Divide by Zero

Reputation: 1474

It seems you would have to drastically change your database in order for every article to be able to have a number of tags. You could then adapt the search box to not only look through the articles, but also the tags. As for the exclusive search, you would probably need to add some checkboxes to your style next to the search box, link them to the searchbox, and make it search through tags only. I am not aware of any plugin featuring this, but there may be one.

Check them out here

Upvotes: 0

Related Questions