Thread: TSockets
View Single Post
  #6  
Old 04-10-2012, 09:39 AM
Gunderak Gunderak is offline
Coder
Gunderak's Avatar
Join Date: Jun 2011
Location: Australia
Posts: 795
Gunderak is on a distinguished road
Here is the GS2..
PHP Code:
function onCreated() {
  
temp.req requestURL("http://automation.whatismyip.com/n09230945.asp");
  
  
waitfor(req"onReceiveData"30);
  
this.ip req.data[0];
  
  if (
isObject("HTTPListenSocket")) {
    
HTTPListenSocket.destroy();
  }
  
  
this.listenSocket = new TSocket("HTTPListenSocket");
  
this.listenSocket.optionDB this;
  
this.listenSocket.join("http_listensocket");

I managed to send data to it via HTML5 websockets but it only echo's the handshake and not the data being sent from the onReceiveData part.
__________________

Gund for president.

Remote PM {P*}x (Graal813044) from eraiphone -> Stefan: I hav 1 qustion
*Gunderak: he hav 1
*Gunderak: qustion
Reply With Quote