Version 25 (modified by Ryan J Ollos, 6 years ago) (diff)

Refs #5831.

Autocomplete feature for the keywords field


The KeywordsSuggestPlugin provides an autocomplete function for the keywords ticket field or any other text-based ticket field. Optionally, it is possible to restrict the list of allowed keywords. The KeywordSuggestPlugin uses the jQuery plugin: Autocomplete for the javascript part.

See also LoomingCloudsPlugin.

Bugs/Feature Requests

Existing bugs and feature requests for KeywordSuggestPlugin are here.

If you have any issues, create a new ticket.

Download and Source

Download the [download:keywordsuggestplugin zipped source], check out KeywordSuggestPlugin using Subversion, or browse the source with Trac.


Sample picture of autocomplete feature

The Keywords Label can be the link to a wiki page.

'helppage' option turned on


Following section must be added to trac.ini configuration file:

field = keywords
keywords = tag1,tag2,tag3
mustmatch = False
helppage = wiki/TicketKeywords
helppage.newwindow = False
matchcontains = True
multipleseparator = ,

There are two parameters to configure:

  • field - field to which the suggestion will be attached (default: keywords)
  • keywords - specifies list of comma separated values available for input
  • mustmatch - optional, if specified, 'keywords' field accepts values from the keywords list only
  • helppage - optional, if specified, 'keywords' label will be turned into the link to a resource. This could be a wiki page, or any resource in any realm, such as the tags page (helppage = tags).
  • helppage.newwindow - optional, whether wiki page opened in new window or not`
  • matchcontains - optional, whether keywords which matched not from the beginning must be included into list
  • multipleseparator - which character(s) is used as separator between keywords. Must be enclosed with quotas or other characters. If not specified, ', ' is used.

Recent Changes

16539 by rjollos on 2017-04-16 02:33:26
Fix indentation
15264 by rjollos on 2016-02-11 04:22:34
Remove unnecessary svn:mime-type on py files

svn:mime-type was set to "plain" for many files.

12103 by rjollos on 2012-10-03 05:38:09

Refs #8141:

  • Moved generation of keywords string into a private method.
  • Several other refactorings, backed by unit tests.
  • In Trac 1.0 and later, jQuery-UI from the Trac core is added to the page. The ability to add jQuery-UI to the page was added in Trac 1.0.


Author: scratcher
Maintainer: rjollos

Attachments (2)

Download all attachments as: .zip