Page 1 of 2

Need suggestions on chat application

Posted: Mon Jun 27, 2005 12:05 am
by raghavan20
Hi, I am thinking of making a chat application. I am wondering which programming language should I use to create the application. Please advise on the best language to be used and why do you think your preferred language should be used?

Do any of you know a good tutorial that would help me creating a chat application? I dont want ready-made chat application but I need some tutorial that would help me do it cos I want to program on my own.

I invite suggestions from you anything that would be relevant to the chat application development.

Thanks for your upcoming comments on the topic

Posted: Mon Jun 27, 2005 12:22 am
by timvw
Just use a language that has the api/modules/extensions/classes ready for you. These days it's silly to write everything yourself, it's a matter of glue-ing the components together.

If you really want to be hardcore, lookup the relevant RFCS, i believe it starts at #1459 and start writing your own IRC class.

Posted: Mon Jun 27, 2005 12:37 am
by programmermatt
I don't think there are any good AJAX chats out there. Make it easily plugged into other apps, and you'll have one popular script.

Posted: Mon Jun 27, 2005 4:57 am
by Chris Corbyn
programmermatt wrote:I don't think there are any good AJAX chats out there.
Not sure it's AJAX or XMLhttp but http://www.e-messenger.net/ does MSN, AIM and Yahoo ;)

Posted: Mon Jun 27, 2005 8:46 am
by programmermatt
d11wtq wrote:
programmermatt wrote:I don't think there are any good AJAX chats out there.
Not sure it's AJAX or XMLhttp but http://www.e-messenger.net/ does MSN, AIM and Yahoo ;)
Should have specified, good OpenSource AJAX Chat implementations. And e-messenger does allow you to login to msn, aim (probably ICQ too) and Yahoo!, and I believe it to be an AJAX implementation, but not truly AJAX, but kinda. I have seen various other sites that allow you to login to messangers long before now and have seen many of them implement similar technologies to AJAX, but long before AJAX.

Anyway, what I was really hopeing for is an AJAX chat run off a single php script using a simple storage method, like a flat-file or DB, that could be easily extended. Every 500 ms or so the page would look for updates and the php script controlling would send from the last time code passed to it via post, and the additional text would just be appended. Problems might be making sure that no one else writes the file when one script is writing, making it highly optimal with minimal bandwith usage, and maybe a simple authentication method that allows it to be plugged into existing projects. Typing this up makes it sound so good I am going to take a stab at it this afternoon.

Posted: Mon Jun 27, 2005 4:10 pm
by raghavan20
Thanks for your views but I am still looking for suggestions to where to start from. Do you know any site links which have got sample chat applications? I hope you will come up with some links to good tutorials on making chat application.

Posted: Thu Jun 30, 2005 12:56 pm
by AngusL
If you can somehow get your hands on the second most recent DirectX 9 SDK, it had examples for writing a couple of simple peer-to-peer or server-based DirectPlay chat things in VB, C# (I think) and C++. Not sure if that's what you're looking for. I believe the most recent SDK got rid of the VB.

Posted: Thu Jun 30, 2005 11:52 pm
by raghavan20
Thanks for your suggestion and you provided me the information about the languages that can be used to develop chat application. I am still wondering are there any tutorials to develop chat applications.

Posted: Sun Jul 03, 2005 1:11 pm
by raghavan20
I am thinking of using Java to write a chat application? what do you think about using Java?

Posted: Sun Jul 03, 2005 1:55 pm
by Burrito
It's really one of only two options you have (assuming you want to keep it web based and you want it to maintain an open connection).

You'll have to write a server side as well and that could be done in any language really (C++, C#, Java etc).

The client piece could be done in Java and included as an applet.

If you're not too concerned with retaining an open connection, look into XMLHttp or Ajax...

Posted: Sun Jul 03, 2005 3:18 pm
by timvw
A very long time ago (had to find it back via http://archive.org) i wrote a ChatProgram.. But be warned, the code is really ugly...

http://timvw.madoka.be/programming/java/ChatProgram.txt

php chat room

Posted: Fri Jul 15, 2005 8:00 am
by thedamo
Just use php, dhtml and xmlhttp object to create a real time chat room. It would mean the user doesnt have to download a java plug in and that they don't have to download the chat program to run..

However it would limit them to using IE, Firefox and Safari..

But that is what I would do :)

Re: php chat room

Posted: Fri Jul 15, 2005 8:47 am
by Roja
thedamo wrote:Just use php, dhtml and xmlhttp object to create a real time chat room.
...
However it would limit them to using IE, Firefox and Safari..
Actually, Opera added some support for xmlhttp in 8. Its enough that it implements all the functionality in gmail, and apparently, upcoming betas extend it further.

So, xmlhttp isn't impossible on Opera, its just challenging.

Of course, you left out Konqueror, which handles it perfectly, and other smaller browsers (camino, iCab, etc) that all handle it just fine too. :)

Posted: Fri Jul 15, 2005 10:41 am
by Burrito
ok ok ok ok....I will post my chat application that I wrote in xmlhttp later today.

keep an eye out in the code snippets forum.

Posted: Fri Jul 15, 2005 12:49 pm
by Burrito