Funnelback logo

Documentation

Tagging (Classic UI)

Introduction

Funnelback's tagging system allows end users to add a list of short descriptions called tags to any URL. This tag information can then be used to show lists of URLs which have been tagged in the same way, and also to improve search results.

The tagging system is most appropriate for use within intranet environments where users can be authenticated and where spamming of specific results is unlikely to be a problem.

Tagging can be enabled or disabled from the "user interface" tab of the edit collection interface, with the enable tagging option.

Displaying tag links in search forms

To display tagging links in search forms, select the appropriate collection, access the edit collection interface, select the "user interface" tab, and then enable the enable tagging option. Then ensure that your search form contains the following HTML elements:

<s:ResPlugin name='ResultTagLink'>tag</s:ResPlugin>
<s:ResPlugin name='ResultTagList'></s:ResPlugin>

The standard Funnelback search forms already contain this markup. The first element enables tagging of results and the second displays a list of tags for each result. This code would normally be placed at the end of each result's display block, which will cause the results to appear as shown in the example below.

TagFormExample.png

Authenticating tagging users

By default, the tagging system requires users to be authenticated before they can edit any tags in the system. The tagging system can rely on the underlying web server for authentication (using any method available to the web server such as HTTP Basic, NTLM etc.). Important note: If your web server provides this information then the secondary authentication system will not be used.

If the webserver authentication information is not available, then the tagging system will rely on its own cookie based secondary authentication scheme. This scheme is for demonstration purposes only and is not suitable for a deployment where real authentication is required.

If real authentication is required that doesn't use web server authentication, then see the Extending the authentication system section below.

The cookie based system requires that usernames and passwords be entered into the special htpasswd file located at <install_root>/conf/tagging.htpasswd (e.g. c:\funnelback\conf\tagging.htpasswd).

The easiest way to enter usernames and passwords into this file is to use the wrapper script provided with Funnelback. Its usage is:

<install_root>\bin\htpasswd.pl <install_root>\conf\tagging.htpasswd tag_user tag_password
e.g.
c:\funnelback\bin\htpasswd.pl c:\funnelback\conf\tagging.htpasswd john passjohn

Modifying a users password is done in the same way — specifying an existing username to the command will change the password for that username.

To delete a user, use the "-D" option to htpasswd.pl:

e.g.
c:\funnelback\bin\htpasswd.pl -D c:\funnelback\conf\tagging.htpasswd john

The tagging htpasswd file can also be edited using the standard htpasswd utility available on Unix. (A Windows version of this tool ships with the Windows version of Funnelback and is available at <install_root>\wbin\htpasswd.exe)

Extending the authentication system

The secondary tagging authentication system can be extended to authenticate against any user information source such as an Active Directory server or LDAP server. To do so, you must write your own perl module that will perform the authentication you desire (Perl's Authen::Simple modules may be a good place to start). The only requirements are that your perl module be made available in your server's perl library directories, and that your module provides a function named authorise_username_password that takes the expected parameters. e.g. :

package YourAuthenticationModule;
sub authorise_username_password {
  my ($class, $username, $password) = @_;
# ... Do authentication here
#
# return true if authentication succeeds
}

You must also make sure that Funnelback knows to use your module by editing the <install_root>/conf/global.cfg file, and replacing the line:

tagging.authentication_module=Funnelback::TaggingAuthentication

with the name of your module. e.g. :

tagging.authentication_module=YourAuthenticationModule

Disabling tagging authentication

If you wish, you can disable the need for tagging users to be authenticated by editing the <install_root>/conf/global.cfg file and replacing the line:

tagging.authentication_required=1

with

tagging.authentication_required=

Including tag data in search result ranking

Tag data is not included in search ranking by default, but may be of benefit in some environments. To enable the usage of tag data for a collection, go to the 'Indexer' table of the collections 'Edit collection settings' page, and set the 'Tag data ranking' radio button to 'On'.

Please note that tag data will only be incorporated when the collection is reindexed, so the collection should be updated before testing the inclusion of tag data.

Customising tag page branding

The default tagging and tag list pages are displayed with very minimal branding, however it may be appropriate to customise the display of these pages to match search page and intranet branding.

The display of these pages is defined by a number of templates stored in <install_root>/web/templates, which use the Perl HTML::Template module.

Each of the templates distributed with Funnelback are named page-name.tmpl.default. To customise the display for a given page, copy the file from page-name.tmpl.default to page-name.tmpl, and make any required changes to the page-name.tmpl file. Please be aware that upgrading to future version of Funnelback will replace the .default files with new versions, and hence these files should not be edited directly.

Tagging arbitrary URLs

The Funnelback tagging system allows the tagging of any URL, not just URLs for results returned with Funnelback. Users will need to add a Javascript "link" to their bookmarks toolbar. Internet Explorer users can right click the link and select "add to favorites", and Firefox / Safari users can drag the link to their bookmarks toolbar. When a page is visited, the user can click this link, which will take them to the Funnelback tagging page. They will then be able to tag the page they were visiting.

The link is:

<a href="javascript:location.href='http://server.example.com/search/tag.tcgi?
      url='+encodeURIComponent(location.href)+'&
      title='+encodeURIComponent(document.title)">
  Tag page with Funnelback</a>

top ⇑