Modify details to criteria function to prevent undefined variable errors

Also improves function readability.
Add tests for Alert class.
Fix some bizzare indentation
Add tests to cover every database call in MEMBER::load_extra_info()
Remove the requirement for short_open_tag in the documentation.

This has already been removed from all code.

Closes #610
Merge branch 'improved-testing'
Update the mySQL class to use PDO functions.
Modify mySQL class to allow execution of prepared statements.
Change all queries involved in home page to use prepared statements.
Replace mysql_real_escape_string with PDO prepared statements.
Remove code which has been commented out since 2010

This is in the git history in case anyone needs to refer to it.
Remove more long commented-out code that uses non-parameterized SQL
Modify how insert IDs are retrieved to sanity check they are numbers, and cast accordingly.
Remove redundant variable declarations.
Reinstate fatal database error message, rather than debug output.
Use PHPUnit group tags to make excluding Xapian-dependent searches easier.
Merge branch 'database-improvements'
Fix broken retrieval of person by Guardian Aristotle ID.
Fix string concatenation in MSP API call
Modify test for $page_data['robots'] to account for possibility of it being unset