Web Application Installer

Almost all distributed web applications has an installer – it makes installation process easier for the end user. I will try to outline some of the most important things to look out for when creating an installer.

Examples of Web Installers

WordPress

WordPress Installer Screenshot

Joomla

Joomla Installer Screenshot

Nexty

I have created an installer for Nexty – I used the same installer for Jus5 as well. Here’s a screenshot…

Nexty Installer Screenshot

Functions of an Installer

Check Requirements

If you software needs the GD PHP extension, check for it – it it is not present, show an error. If any folder must be writable, check for that. Make sure that the user cannot go to the next page without solving all the problems.

Make sure you have provided clear instructions on how to solve the problems – changing the permission might be easy for you and me – but the average user will find it very hard.

Database Connection Details

The user have to provide this data if our system uses a database.

  • Host
  • User
  • Password
  • Database

In some applications, the user must manually enter these data into the config file(for eg. WordPress). In other software, the user have to enter it at the time of installation. For example, Joomla uses this method – as does my application, Nexty.

Create tables and insert initial data

Check for existing data first – you don’t want to delete the existing data when reinstalling the software. This step is necessary only if you are using a Database in your application.

Save the inputted data

The user inputted data must be saved – in my application I just write it to the config file. But for that to work, the config file must have write permission. I also give the user an option to copy the code and place it in the config file themself.

Joomla also writes the values to a config file. However, WordPress inserts the data into the database. The only thing in the config file in wordpress is the database connection details – which the user must enter manually.

Disable the Installer

Make sure that the installer cannot be run after the installation is successfully compleated. This is important for the security of the application. You really don’t want any Yahoos opening up the install URL of your application and resetting all the data!

The easiest way of doing this is just deleting the installation script/folder. Joomla insists that you remove the installation folder before letting you use the application. In Nexty, removing the installation directory is recommended – but not enforced.

More on Web Installers in the next post.

1 Comment

Comments are closed.