added the mysqli changes