added xmlHttpRequest for user data submission to server