in reply to Cgi script with no output to webpage?
The script should not return anything visible to the page that called it.
So return something invisible ;)
You could either put the response in a hidden iframe with a style visible: none; or send a Content-type text/html with no visible content.