Refactored database code to localise DB library dependencies into
db_connect. First stage in refactoring away from PEAR.
Move from PEAR DB to PDO (1 of 2)
Move from PEAR DB to PDO (2 of 2)
Move from PEAR DB to PDO (3 of 2) (accidentally knobbled mediawiki)
Repair error handler. Fix some E_STRICT warnings due to latest PHP version.