PDO Updates

updated a few prepared statements in the functions.php, also minor bug
fixes
Merge pull request #2 from favorspin/pdoupdates

PDO Updates