use mysqli connection as global variable