I don’t know, what code it is, but it is not JavaScript.
JavaScript is a loosely typed language, so the stuff with the colon (which I suspect as type hinting) should throw errors.
even without that, there are problems
- <script type="text/javascript">
-
function onVideoStopped(VideoEvent)
-
{
-
// URLRequest is not defined
-
// any new call "new URLRequest()" will use the local variable and thus fail (in most cases)
-
var URLRequest = new URLRequest("http://google.com");
-
// navigateToUrl() is not defined
-
// url is not defined
-
navigateToURL(url, "_self");
-
}
-
</script>
-
event listeners are defined using the
addEventListener() method (at least where DOM is concerned).
onVideoStopped is not a HTML event.
but I don’t know, how the flash implementation of JavaScript works, so you better ask in the Flash Forum.