MySQL connection pinging and escaping!

- Added MySQL connection pinging and reconnection upon connection failure
- Added MySQL escaping to allow for escaped variables to be used without mysql injection
- Added a few minor fixes and other crufty cruft crap