use PDO instead of mysqli

we still depend on MySQL, but PDO allows for simpler syntax in some
cases