Addition of safeInput() to prevent SQL injection

The addition of protection against most basic forms of SQL injection by filtering your input variables through a safeguard. This is done through the safeInput() function, that also takes the actual database connector as an variable (not required!).