Hello Friends, I am making a chat applet server application. I have made it with Sockets but as socket doesnt work behind proxies ( till i know, if you know how to get a socket in an applet to work behind a firewall then it will solve all my problem.) But rite now i am trying to work with URLConnection. I open up a new urlconnection from the applet & connect it to the server at port say 1234. I store the output & input streams of the URLConnection & then by using 2 different threads i read & write to the server. I can read all the messages sent by server through input stream of urlconnection. But i just can send only one message through the output stream of urlconnection. why am i not able to send mulitple messages using a thread through the output stream of urlconnection?? Please help me out with it. If code needed please let me know Ill paste it... its a bit long one.Thanking you in advance. Cheers Nehal.
If you are using the http protocal and a servlet to provide the server side, http is a sessionless protocal and that could be the source of your problem. If you want a chat search and you could find one that over comes this problem. I believe there is one at JFind just click the link below.
Hi Carl, Thanks for the reply.. but where is the link? & i am not using servlet. I am using a java application which runs 24hrs/365 days.. All i want to know is can you send multiple messages ( strings ) using URLConnection's output stream?? please post the link Thanks once again for your effort.