Added functionality to send data to webserver