Request Tracker - Hacks

On this page I'll post some of my modifications for Request Tracker.

Auto Complete Email

To help users enter people's email addresses into Request Tracker, I wrote a bit of Javascript to query a list of emails as the user typed in a name and display the results as a drop down list that could be selected.

How does it work? The Create.html and Update.html screens are modified to use a "SelectEmail" element wherever an email address is needed. This Mason file creates the necessary elements for the drop-down to occur. Now whenever you start typing in a name on that screen, your browser will query /cgi-bin/email-autocomplete.cgi, which performs an LDAP query with the name you entered, returning the results, which your web browser will display as a dropdown.

I wanted to do a better job packaging this, but unfortunately that's a lot of work so it will probably never happen. Because of this, it will probably be harder for you to get this to work. Anyway, here are the files:

First, unzip the autocomplete.zip file into /opt/rt3/local. The zip file includes two patch files. For those patch files, you'll need to copy the corresponding file from /opt/rt3/share/html to /opt/rt3/local/html and use the patch utility to create the new file.

Second, setup a cgi-bin directory on your webserver. Add something like this to your Apache config:


    SetHandler None

ScriptAlias /cgi-bin/ "/opt/rt3/cgi-bin/"

    AllowOverride None
    Options None
    Order allow,deny
    Allow from all

Download the email-autocomplete.cgi file to /opt/rt3/cgi-bin. Edit the LDAP_ variables found near the top of the file. Give it execute permission. You may also need to install the following CPAN modules: Net::LDAP, Cache::FileCache. You can try running the .cgi program from the command-line to see if it chokes on any missing modules.

Restart Apache so that it picks up the changes.