I have a script which uploads data to my web server running Apache/PHP 5.3, the request includes some additional headers which may mean that the request should be terminated instantly as the data is not required. My question is, how do I shutdown the incoming socket with PHP?
I’m reading from php://input but calling fclose() just kills my copy of the socket and so the script keeps on sending the data even though the receiving script has given up.
Is there any way to do this?
Thanks,
J
stream_socket_shutdown()