added sendRequest to webpage as a function