10 Replies Latest reply on Oct 6, 2010 11:01 AM by daslicht

    flex chat application

    flex_able Level 1

      I want to make a chat application......in flex...which way should i movee.....
      any examples??
      any tutorials??
      which is the best n simplest wat to do it........any particular server used......
      can i used as3 socket programming??

        • 1. Re: flex chat application
          ArrowUpRight Level 2

          as i know, you should go and learn about databasing fb, to be able to send to and retreive data from server.

          this is a good tutorial:

          http://www.youtube.com/watch?v=x-Da1SD1Ykk&feature=related

          • 2. Re: flex chat application
            flex_able Level 1

            any suggestion folks........waiting to listen more

            • 3. Re: flex chat application
              Claudiu Ursica Level 4

              The answer(s) is  "it depends". You want to build it for educational purposes?

              It also depends on the server side solution. Socket works just fine, I built

              myself chat applications against a C, C++ server using sockets. I can vouch for

              the fact that it worked. However at the same time the server could process HTTP

              requests so I made it flexible and easy to switch. Both approaches work. Your

              could use FMS in the backend and local/remote SharedObject(s) and NetConnection

              to send data back and forth. That also works. So here is the it depends part.

              What is your goal? Do you already have the back-end built? If is just

              educational install a FMS on your local machine and you can google for an

              already built version. In half a day you could have it running ...

               

               

              My 2 cents,

              C

              • 4. Re: flex chat application
                samschauhan

                You can use LCDS.

                • 5. Re: flex chat application
                  flex_able Level 1

                  i want to learn some thing core abt server connections ...... that shd help me to understand how they work how they send n receive data........in that context shd i use as3 socket programmimg??

                  will it help me to make a chat application??

                  any suggesions?

                   

                   

                  or theres something else that helps me to learn sever connectivity better?

                  • 6. waiting for repliess
                    flex_able Level 1

                    ????

                    • 7. Re: flex chat application
                      Claudiu Ursica Level 4

                      In my opinion the more complex part is writing the server side... Once you have

                      that the client comes quite straightforward. There is no such thing as bad

                      experience at least if you learn something from it. So go ahead with sockets.

                      Once you feel you master them well enough move to something else... You said it

                      yourself that it is for learning purposes...

                       

                       

                      C

                      • 8. Re: flex chat application
                        vineet osho Level 1

                        Hi friend

                                       i have no idea of sockets.but i have made sevral chat application in flex using streaming server.

                        there are three ways using streaming server:-

                        FMS(Supports As1.0)

                        Wowza Media Server(Support Core Java as server side)

                        Red5(Support Advance Java as Server side).

                         

                        i worked on all the three server.it is not a tough part.just download any server and check test chat aaplication.still having any doubt the please let me know.

                        but its quiet intersting to use sockets in flex chat aaplication.i am very excited can you give me some guidance regarding this.

                         

                         

                        Thanks And Regards

                          Vineet Osho

                        • 9. Re: flex chat application
                          Claudiu Ursica Level 4

                          I am not sure if there is some ChatServer socket available for download like FMS

                          or the other 2 you mentioned. I only worked with already built by other people

                          servers. So my client needed to comply wit that server (happened to be written

                          in c/c++). Custom communication protocol and other stuff. In the end Socket

                          programming comes down to producing bytes and send them down the pipe. You can

                          write your own simple server which could just open a socket and listen for

                          incoming connections and then just display the message on the console and send

                          it back to client. Something like this link does...

                          http://insideria.com/2009/11/using-udp-socket-connections-f-1.html . Please bear

                          in mind that this uses datagram sockets (UDP), it is a lower level comunication

                          than TCP/IP. But you can get an idea of the basics. Instead of udp sockets use

                          simple sockets from as3 and you could do the same for start.Take it as an

                          exercise modify the code both client and server side to be compiant with tcp

                          sockets instead of upd sockets.

                           

                          C

                          • 10. Re: flex chat application
                            daslicht Level 2

                            Basically you have 2 choices:

                             

                            Polling or Serverpush

                             

                            Polling:

                            Your client looks on the server if there is a new message for him in a predefined intervall.

                            That means any client which is connected is pinging continiously your server.

                            You can easily solve this with PHP.

                             

                            Serverpush:

                            The clients register to the server and once one clinet send a message to the server, thew server sends(forward, push) the message

                            to the connected clients.

                            This is not possible with php , you need something like JAVA

                            You can try it with BlazeDS(free) or even simpler by using Adobe Stratus, Cirrus, AFCS or however they call it these days (they rename it so often)

                             

                            Happy Coding!