FEATURE: Add database internal versioning and upgrade path.

Adding a settings table and setting initial database version to 0.

Future database upgrade will be placed in db/upgrade/number.db. The
application will find the upgrade files and execute them in order and
make the database upgraded.

A point to remeber is to check if the upgrade is needed, someone can
have applied the change on before hand for whatever reason and they
should not have duplicate entries and what not.
FEATURE: Introduced PDO interface class, and added testcase in functions.php
REFACTOR: Remove dashboard entries without relevance.

There were some dashboard entries added to the view that was merely
placeholders. Removed them to make the dashboard easier to grasp.
REFACTOR: getNumberOfMembers(type) acount for active dates.
BUG: Unicode is a ugly thing. Don't pass around ö in database selections.

Stöd -> Stod
REFACTOR: Replaced mysqli references with mysql in updatePerson
BUG: Removed all the redundant calls to mysql real escape string.
BUG: fixed wrongly named var in setAPIPersonData.
BUG: Get current members in report is wrong

This is due to multiple periods overlapping oneanother.
What I've done is that I've made sure that there will be only info regarding
the person and not the period type in the report (as stated in the name).
Also, there will be an group by on the SSN just to make sure that
we avoid duplicate entrys for members.
BUG: Not able to add new users correctly

Since we moved over to PDO, mysql_real_escape_string will cause major problems.
This is why I've removed the last mysql_real... from functions.php

With this fix we are able to add new users correctly
BUG: Number of Members is wrong

Added DISTINCT to the select of ids from personer since we only want
one entry if that id is a member
BUG: Get non members not giving correct info

The non-members suffered from the same problem as getMembers did.
So with a little magic and negative expression we made it work.
(Read: took the code from getMembers and inverted the if-check)