User Tools

  • Logged in as: anonymous (anonymous)
  • Log Out

Site Tools


mantisbt:mantis_search_plugin_for_mozilla_firefox

Mantis Search Plugin for Mozilla FireFox

The Firefox search bar is a very useful feature. Just click Ctrl+K, type in the text to search for, then click Enter. The same feature would be very useful for locating Mantis issues. This post explains how you can get the search bar working with Mantis.

Preview Image of Mantis Search Plugin

www.futureware.biz_blog_files_firefox_mantis_search_plugin_mantis_search_plugin.jpg

A Firefox search plugin is implemented via two files: - name.src: A mandatory XML file that has the definition of the plugin. (this example mantis.src) - name.png: An image file that is 16×16 pixels (other formats are supported, e.g.: .jpg and .gif). This file is optional.

Following is the content of the .src file:

# Mozilla/Mantis plug-in by Victor Boctor (http://www.futureware.biz)
<search
    name="Mantis"
    description="Official Mantis Bugtracker"
    method="GET"
    action="http://bugs.mantisbt.org/view.php"
    queryEncoding="utf-8"
    queryCharset="utf-8">

    <input name="id" user>

</search>

The src file above defines the name and description of the plugin. It also defines the form that will post the user input to Mantis. The form is defined by choosing an action domain, the post method, and the encoding. The form has one field “id” which is set to the value of the user input. We use this for the BugID#. You can change this search plugin (or define another) which links to your own Mantis installation. Just change the action domain to “http://www.yoursite.com/mantis/view.php”.

Says 'post' but actually uses 'get'…FIXME

Place the 'src' and optional image files in the searchplugins directory: “C:\Program Files\Mozilla Firefox\searchplugins” or “/Applications/FireFox/Contents/MacOS/searchplugins” Your path may be different based on the path chosen during installation and the Operating System on which Firefox is installed.

Download now the src and image file. ( just copy the source but where is the icon?FIXME)

These are tested on Firefox v1.0.6. (and the source on FireFox v2.0.0.3 )

When this feature is integrated directly into Mantis, the following features will be available:

  • It will be possible to auto-install the search plugin using Javascript.
  • The plugin will point to the Mantis installation it was installed from.
  • Support for auto-update of the search plugin.
  • Support for search for text, rather than just searching by issue id.

It would be nice if someone can re-do the same plug-in for Internet Explorer 7 which has the same search bar concept.

mantisbt/mantis_search_plugin_for_mozilla_firefox.txt · Last modified: 2011/11/16 07:34 by atrol

Driven by DokuWiki