Short to Long URL Redirection, a Domino Apps

A Short URL redirection to a page with a really long URL

Are you using any of the redirection services from tinyURL when composing your Twitter or Facebook entries? Then this may be a solution that enables you to use your own URL and still have a short version. This ShortURL application creates a log entry for the redirection in the Domino Web Server Log. You don't have this information with a 3rd party redirection, well, unless you subscribe to their service.

Redirections is not new to Domino, the problem is that it is configured in the Domino Directory. Any change to the web configuration requires special authorization and a refresh of the HTTP task. The Domino Redirection works fine within a limited number of entries. The maintenance becomes a nightmare as soon as you have too many redirects.

This application solves that problem even to the extent where you can setup the application for your department(s) and the users all setup their own short URL. Completly secured with ACL to work for their group or department.

This application is distributed free of charge and the author assumes no responsibility for errors or omissions.

To download the database, click here

All current setup and configuration instructions are in the Using This Database

+++++++++++++++ Copy from Using This Database below +++++++++++++++
+++++++++ Refer to the Using document for up-to-date instructions ++++++++

Installation Instruction

This application uses the Domino Server Internet Sites Substitution Rules.

Audience: Domino Administrator

1. Server Document, Basic Tab, Load Internet configurations from Server\Internet Sites documents must be enabled
2. Web>Internet Sites has to be configured with the web site

Database installation:
The groups LocalDomainAdmins and LocalDomainServers have Manager Access.
Sign the database with your ID to prevent warning messages.
Update the ACL to work in your Organization.
ACL setting > Anonymous must be Reader
Copy the database to the server where the HTTP task runs.
The documentation assumes that the database name ShortURL.nsf was not changed.

Create the Substitution Rule:
1. Open the Web Sites document (view mode is fine)
2. Click Action>Web Site... and select Create Rule
3. Add a Description, eg Short URL redirect
4. Change Type of Rule to Substitution
5. Set Incoming URL pattern to /go/*
6. set Replacement pattern to /ShortURL.nsf/($go)/
7. Click Save & Close in Action bar
The entry will look like this
This change does not take effect immediately. You need to refresh the HTTP task.
To refresh enter the console command Tell HTTP refresh or wait for the refresh to take effect overnight.
CAUTION: The refresh may interfere with other functions, please consult the manual for details.

Create a redirection:
Click the New ShortURL action
Enter the long URL in the Destination URL
Enter a short URL in the Short URL only
Click Exit and save.
The entry will look like this
Test the short URL version.
Example as per above configuration
In the browser, enter the URL
To make the URL even shorter, you can omit the www in the URL if you have the corresponding DNS entry.
This shorter version would be
To find out if this works, just enter the and this should open the same home page as the URL with the www. If you get an error, use the www in the URL.

How to create other redirections?
The example uses the 'go' string in the short URL. This is the key for the substitution and has to match the Incoming URL pattern in the Substitution Rule. You can have as many variations as needed, but every variation should have it's own database (ShortURL1.nsf, ShortURL2.nsf and so on). Every database needs it's own Substitution Rule.
This is useful if the redirection is used by different organizational unit. Sales could use and Manufacturing could use Both short URLs will point to a different catalog.
CAUTION: do not use a single number as short keys.

First published on October 06, 2010 Contact Us  Help