Second Site

Second Site - Overview

Second Site is a framework aimed at building relational database templates with a particular focus on spatial elements.

Second Site is a framework I developed for creating relational database templates which can be readily adapted to meet the changing requirements of whimsical funding policies. It has some focus on spatial data, versioning, encryption, audit trail and extensibility. The database creates tables from the template definition as they are referenced so you only end up with the tables you use.

Part of the aim of Second Site is to hide the terminology and complexity of relational databases from the user so for example many to many links are implemented by way of an intermediary table which is never seen. All the user sees is that they can discuss multiple sites at one meeting or discuss the same site at multiple meetings.

Second Site Mapping

Second Site using GoogleMaps API to provide an interface for the Map Data column type.

The system supports a number of named data types which are associated with interface methods to populate or view the data. In this way you only have to code the interfaces to each data type, the interface for a given table is built from the lego bricks of the data type interfaces. This means you can add a new table to the template and have it appear in the user interface by doing little more than specifying a table name and the column names and types. Because the tables are created by the application, the new table is created next time it is referenced and appears in the UI as soon as its definition exists.

Second Site User Interface

Different column types present different interfaces. The link to many option allows the creation of many to many links using a hidden intermediary table.

At present new table definitions need to be added to the PHP database template by hand but I intend to add an interface to allow the user to create new table definitions stored in the database.

Whilst Second Site can be run over https, it also supports some native encryption both in terms of transmission of data between server and client and in the database. One of the aims of Second Site was to add as much function in an entirely free version as possible so people who either can’t justify the expense of an SSL or who don’t have the in-house expertise to implement one can still get some level of encryption and data security.