FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » chat on web, Ajax ?
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: chat on web, Ajax ? [message #177171 is a reply to message #177161] Fri, 24 February 2012 16:31 Go to previous messageGo to previous message
SL is currently offline  SL
Messages: 20
Registered: February 2012
Karma:
Junior Member
> That is the problem: typical http requests data from some server, and
> after it arrives, that's it.
> A normal http request:
> 1) Browser sends request to server.
> 2) server answers
> the end.
> How to let the browser listen to the server?
>
> Short answer: You cannot. Not without some tricks or additional
> software (Java, Flash for example).
>
> Read up here first:
> http://en.wikipedia.org/wiki/Push_technology#HTTP_server_push
>
> You can see on that page that a few experiments have been tried, but
> none of them if fully reliable.
> For example: multipart/x-mixed-replace is not supported by IE, and I
> don't know about mobile devices.
>
> You have 2 options:
> 1) Make a client-pull approach, eg with XHR ("Ajax").
> http://en.wikipedia.org/wiki/XMLHttpRequest
> Advantage: Easy to implement.
> Drawback: All the connected clients will be sending update-requests
> all the time. This will lead to extra serverload which can kill the
> server if you have many clients trying to chat.
>
> 2) Use additional software that CAN listen.
> Problem: See former thread: Suppose your server wants to PUSH new data
> to some client: How to deliver that behind a firewall/NAT? To which
> port?
.....
.....

Yahoo has a messenger that is implemented on web; one can see it after
logging in to check mail.

With such serious shortcomings, I suppose they have to have a larger server
farm to take care of the load from chatting.

:-) :-)
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: FastCGI & PHP
Next Topic: PHP socket and NAT
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Sun Nov 24 09:54:13 GMT 2024

Total time taken to generate the page: 0.07161 seconds