I dont think that sending any data to another window is PHP's business.May i remind you that PHP is a server side scripting language?
It's obvious that that method wouldn't work out because of the basic rules of Protected Mode Computing.
But it's not the only thing i'm going to say... Here what pops up in my mind when i read your thread..
An ActiveX component can be prepared and embeded in HTML file. By rising events with ActiveX, you can even make it interract with JavaScript and dynamically add/delete/update the content of the main HTML web page by using DIV tags .innerHTML property.
And at the back end, ActiveX can have a Peer2Peer connection to the massage handling software via socets which is located in the same computer or running remote.
But here's what would happen if you use ActiveX solution...
-Client browser downloads the HTML
-ActiveX starts running, opens a socet to the server. listenes for a message to arrive
-While this occurs client user has a static page...
-When a message is recieved, Active X sets a Javascript variable with the info of newcoming message and then rises an event,
and an even handler routine written with Javascript running at
-Clients browser takes the new message and publishes it by setting document.getElementById('idOfBuffer').innerHTML property.
-The backend is as a usual socket connecting software