Add curl Timeout and Connection Timeout for send function.

Add a connection timeout, so if the connection to the server fails or hangs a failed response can be returned to the PHP script. This stops the PHP from timing out waiting for a failed connection or response.