changed mysqli calls to not use the object-oriented version