vid 29&30:
added new mysqli objects in openConnection function, also checks for error
added if statement for isset within closeConnection function