Lead Hat Limited offered Internet and Web consultancy, design, hosting and web applications development.
The website was one of several designed around this time by Pete McDonagh at Codesign.it, who Adrian had met while working on the 2000 London Election project.
With a strong technical offering, Lead Hat offered a number of computing technologies for website development, including:
ColdFusion
Microsoft Active Server Pages
PHP
Microsoft SQL Server
MySQL
Oracle
C, C++
Owned 20% by FirstVirtual Group plc the company started offering web development services in 2000, just a few months before the ‘dot com crash’ of March to October that year partially wiped out demand for its services.
Despite the ‘dot com crash’ Lead Hat picked up some good clients and had notable success with:
2001 UK General Election – A website developed in partnership with the Daily Telegraph newspaper to cover the UK General Election of that year.
Wild Bunch – A website and content management system for the film distribution company.
In 2002, having had a lean time in the web development services business, Adrian Tear and Tony Sellen abandoned this sector in favour of developing consumer websites of their own.
The new business, Allegran Limited – founded in 2002, went on to develop lottery, dating and property websites. It was sold to Daily Mail General Holdings three years later in an eight figure deal.
The 2001 United Kingdom General Election was held on Thursday 7 June 2001.
Having produced a ground-breaking website for the 1997 UK General Election, Adrian and his colleagues were keen to repeat the exercise for 2001. Some of the data from 1997 could be re-used in the 2001 website, e.g., to calculate swings, while a complete re-design featured new navigation (without frames), new maps, much more data and expanded expert commentary from Dr Robert Waller and Dr Byron Criddle, co-authors of The Almanac of British Politics.
Work on the project was in hand before Adrian and his business partner left Business Geographics Limited in late 2000 to co-found Lead Hat Limited, a full service Internet development agency. Their departure did not go particularly smoothly and, for some time, it looked as if the possibility of publishing a 2001 Election website under the Lead Hat brand, or at all, was in doubt.
Happily, however, several of the ‘cease and desist’ letters that were issued at the time failed to escalate, and Adrian started working alongside several former freelance programming colleagues from Albedo Systems Limited, plus new data partners CACI Limited (for geodemographics and income profiles) and the Automobile Association Limited (for base maps).
A media partnership, following discussions with several interested parties, was again announced with Telegraph Group Limited, publishers of The Daily Telegraph newspaper. This arrangement provided some funding and, crucially, integrated the team’s maps and data with the Telegraph’s online press coverage.
The Election 2001 website was notable for a few innovations, mostly hidden behind the scenes:
Database-driven pages featuring maps, data, text and graphs were published from a custom-built Content Management System (CMS), written in ColdFusion over a Microsoft SQL Server 2000 database, to static (.htm) HTML files.
These static HTML files, together with image files, several ColdFusion (.cfm) files required for search and all the other ephemera needed for the website, were copied by the CMS to a staging server. A full run to update and replace all files took ca. 45 minutes.
The CMS also offered mechanisms for Robert Waller and Byron Criddle to upload or update their constituency and candidate profiles remotely, and for Telegraph journalists to add links to constituency pages or body copy.
On Election night a small army of Telegraph staff watched the television and the wires and updated the results as they came in. Updated pages with results were deployed to the live webservers, once again as static HTML files.
The site ran on a small fleet of load-balanced Windows NT webservers running Microsoft’s IIS (Internet Information Services) in a co-located Level 3 hosting centre in the old Gordon’s Gin factory on Goswell Road, London.
The CMS system worked very well, and the publication to static HTML completely eliminated frustrating problems encountered earlier running a high usage site with many database queries (not enough of which were cached, probably) straight from ColdFusion, which had just been re-released as a somewhat flaky Java-based server that didn’t play all that well with Microsoft Windows NT.
Getting this old site going again has been a journey in its own right, requiring a mix of database, computing infrastructure, coding and expert knowledge acquired back then but updated for the Cloud and open-source era.
If you’re looking at doing something similar the advice below may be of some use, or perhaps some consultancy might help?
How to restore a SQL Server 2000 backup to SQL Server 2025
Fortunately, Adrian had taken a backup of the 2001 Election website. Unfortunately, this backup was made using an ancient version of the Relational Database Management Software (RDBMS) Microsoft SQL Server 2000. The backup (.bak) files would not restore on SQL Server 2025.
SQL Server 2008 R2 Express would restore the SQL Server 2000 database. It was then necessary to issue some Structured Query Language (SQL) and/or Transact-SQL queries:
SELECT
name,
compatibility_level
FROM sys.databases;
The following statement was used to update the compatibility_level for the old, restored, database.
ALTER DATABASE "[DB_NAME]" SET COMPATIBILITY_LEVEL = 100;
The first query was re-run to check this had worked, which it had, and the database was then backed up in the normal way from Microsoft SQL Server Management Studio (the version bundled in the Microsoft SQL Server 2008 R2 Express with Service Pack 2 link above).
Having not used Microsoft SQL Server in years the next stage was the most amazing…
The installation instructions are detailed and easy enough to follow and, so long as you’re running a VM with at least 2GB RAM, Microsoft’s RDBMS software will install. Adrian created an Amazon AWS Lightsail instance running Ubuntu 22.04 but he could have used a VM on AWS, Azure or GCP as the host for his SQL Server 2025 database.
Running the following query in SQL Server Management Studio 21 connected to the server (with appropriate firewall rules etc.):
select @@version;
Returned:
Microsoft SQL Server 2025 (CTP2.1) - 17.0.800.3 (X64)
Jun 12 2025 14:47:57
Copyright (C) 2025 Microsoft Corporation
Express Edition (64-bit) on Linux (Ubuntu 22.04.5 LTS) <X64>
The compatibility_level=100 backup file could now be SFTP’d up to the Cloud Ubuntu Linux VM (to /tmp, not forgetting to chown root:root [backupfile.bak]) having hopped from SQL Server 2000 to 2008. The backups, taken in 2001, could now be successfully restored via SQL Server Management Studio on the Ubuntu RDBMS box.
So, a Microsoft (Windows) SQL Server database structured and populated in 2000/2001 could be used in 2025 on a Cloud-based Linux server running Microsoft SQL Server 2025. Amazing…
How to install and run Lucee CFML server
ColdFusion was initially released by Allaire, later taken over by Macromedia and later still subsumed by Adobe. While you can still buy a ColdFusion licence from Adobe there is a free, open source alternative: Lucee.
The Lucee CFML server and extensions may be downloaded for Linux, Windows, as a WAR file for a Java servlet or in several other flavours. Adrian chose the Linux (x64) Installer version for use on another Ubuntu Amazon AWS Lightsail instance.
cd
wget https://cdn.lucee.org/lucee-6.2.1.122-linux-x64-installer.run
sudo chmod +x lucee-6.2.1.122-linux-x64-installer.run
sudo ./lucee-6.2.1.122-linux-x64-installer.run
The installation runs smoothly enough in a text-based SSH environment and, upon visiting your installation in a browser at http://[your_public_ip_address]:8888/ you should be greeted by the words ‘You are now successfully running Lucee 6.2.1.122 on your system!’ If not:
Make sure you have assigned a public IP address to your Lightsail instance or EC2 VM etc.
Make sure you have opened port 8888 in the Lightsail (or EC2 etc.) firewall but restrict access to your own client IP.
The package installed Tomcat Version: 11.0.6 and Java: 21.0.7+6-LTS on an Ubuntu 22.04.5 LTS VM running Apache2. Once the installation process is complete your public IP address should have a Lucee admin server at:
In addition to firewall rules Adrian chose to further secure his Lucee installation by enabling Captcha but received the message ‘Fontconfig head is null, check your fonts or fonts configuration’.
A quick search revealed a possible solution to the problem, while a second search showed that font ttf-dejavu had been renamed necessitating the following command.
After a restart of the computer (sudo shutdown -r now) the Lucee admin page has Captcha and all is reasonably secure.
How to set permissions for /var/www
The directories and files off /var/www on a Linux webserver should have appropriate permissions for (Apache2) access and (external) security.
Every time Adrian has looked for the answer to this question he has found competing, and sometimes incorrect, advice.
For a machine (e.g., an EC2 or Lightsail VM) where ubuntu is the sudo user (use getent group sudo to list the sudo users) and www-data is the Apache2 webserver group his preferred solution, based on some research, is:
These commands can be saved in a shell script (e.g., fix_perms.sh in /var/www) containing the lines:
#!/bin/bash
sudo chown -R ubuntu:www-data /var/www
sudo find /var/www -type d -exec chmod 2750 {} \+
sudo find /var/www -type f -exec chmod 640 {} \+
# make this file executable again!
sudo chmod +x fix_perms.sh
Whenever files have been uploaded to the webserver (perhaps from a machine with a different sudo account or webserver group) permissions can easily be set up correctly using the commands:
cd /var/www
sudo ./fix_perms.sh
This approach has saved a lot of scrabbling around for solutions to the octal permissions problem, hardly any two of which are the same.
How to set up Apache2 for case insensitivity
Many of the old websites Adrian and his colleagues developed were built on Microsoft Windows NT running the IIS webserver.
While NTFS, the file system used by Windows NT and its successors, is technically case-sensitive, Windows applications generally treat file names as case-insensitive by default. IIS would serve index.cfm, Index.cfm or INDEX.CFM regardless of the filename.
The Linux operating system, and Apache2 webserver, are case sensitive, so the HTML <a href="myfile.htm">click here</a> would fail if the link to myfile.htm was actually MyFile.htm on the filesystem.
Thankfully, help is at hand when migrating ancient case-insensitive websites developed under Windows to Linux…
Then, in the .conf file of the website in question (in /etc/apache2/sites-available on Ubuntu Linux) be sure to include (watching out for the spelling of mod_speling) the highlighted text.
<VirtualHost *:80>
DocumentRoot "/var/www/election2001/htdocs"
ServerName election2001.adriantear.com
DirectoryIndex index.cfm
# Other directives here
<IfModule mod_speling.c>
CheckSpelling On
CheckCaseOnly On
</IfModule>
</VirtualHost>
All the incorrectly-cased links to files or files that were incorrectly-cased now become irrelevant and your ancient website should operate, largely, as originally intended.
A website with image mapping functionality, and that also has casing problems in filenames or links as above, should therefore incorporate the AddHandler imap-file map clause as per the highlighted .conf file below:
<VirtualHost *:80>
DocumentRoot "/var/www/election2001/htdocs"
ServerName election2001.adriantear.com
DirectoryIndex index.cfm
# Other directives here
AddHandler imap-file map
<IfModule mod_speling.c>
CheckSpelling On
CheckCaseOnly On
</IfModule>
</VirtualHost>
All of this server setup, database and webserver configuration work can be enjoyed at the restored 2001 UK General Election website…
Give the old site a visit and think about some of the steps involved in getting it working properly again.
Thank goodness for Web ARChive (WARC)files that can store content from websites regardless of server set up, so long as the sites are working at the time and the crawling is thoroughly comprehensive.
Founded by Adrian Marshall in 2000 and 20% owned by FirstVirtual Group plc, Lead Hat Limited started offering database-driven web development services in 2000, just a few months before the ‘dot com crash’ of March to October that year partially wiped out demand for its services.
Lead Hat Limited was a full service Internet agency providing everything from server hosting through to brand management, system design and implementation.
Despite the ‘dot com crash’ Lead Hat picked up some good clients and had notable success with the 2001 UK General Election website, a fine arts auction website and a database-driven website for film distributors Wild Bunch.
The 2001 United Kingdom General Election was held on Thursday 7 June 2001. Having produced a ground-breaking website for the 1997 UK General Election, Adrian and his colleagues were keen to repeat the exercise for 2001. Some of the data from 1997 could be re-used in the 2001 website, e.g., to calculate swings, while a…
Lead Hat Limited offered Internet and Web consultancy, design, hosting and web applications development. The website was one of several designed around this time by Pete McDonagh at Codesign.it, who Adrian had met while working on the 2000 London Election project. With a strong technical offering, Lead Hat offered a number of computing technologies for…
In 2002, having had a lean time in the web development services business, Adrian Tear and Tony Sellen abandoned this sector in favour of developing consumer websites of their own.
The new business, Allegran Limited – founded in 2002, went on to develop lottery, dating and property websites. It was sold to Daily Mail General Holdings three years later in an eight figure deal.