This is the client part, it's written in actionscript 3, this works:
public function Connect()
{
socket = new XMLSocket();
socket.connect(hostName, port);
}
When I trigger this code I recieve a policy file request on my server, and I am able to send the policy file back without any problems, this is handeled by this bit of code at the end of my recieve function (server);
if (msg == "<policy-file-request/>")
{
sendToClient("<?xml version=\'1.0\'?><cross-domain-policy><allow-access-from domain=\'*\' to-ports=\'*\' /></cross-domain-policy>",tcpClient);
myInterface.logTxt.Invoke(new AppendTextDelegate(writeIntoLog), "Policy file sent."+Environment.NewLine);
connClients.Add(tcpClient);
break;
}
See the SendToClient function in my first post.
This all works, when I only accept one client and keep the connection open I am able to send and recieve to both sides, when I try to send using the list with clients I dont recieve anything on my client.
Sending from client to server works all the time.