I wonder if you couldn't use an AJAX call to try to download the contents of the script? You can set the timeout for the AJAX call to a very short interval. You don't really care if you get trash as the response; you just want to test for the existence of the response.
In fact, I think I'd use a SYNCHRONOUS call (SJAX?) with a really short timeout (2 seconds?) and handle the failure gracefully.