myURL = this._url; myPos = myURL.lastIndexOf("/"); myBase = myURL.substring(0,myPos+1); // Wide open policy // System.security.loadPolicyFile(myBase + 'policy.xml'); mySession = _root.cid; myPort = _root.port; myClient = _root.client; s = new XMLSocket(); s.onConnect = handleConnect; s.onData = handleData; s.onClose = handleClose; s.connect(null, myPort); function handleConnect(success) { if(success) { s.send(mySession + ':' + myClient + "\n"); } } function handleData(input) { getURL('javascript:declockFlashCallback("'+escape(input)+'");'); } function handleClose() { }