ho, this.?? :) chat problem. :) easy.. think other way..
when you write your response from a chat Windows, with same session, don't update the Windows directly from the send command message, update from the push update made by ape.. you sent your command to the server, ape return you your messages, same as a message from other , but with your ident.. by this way, all Windows chat are naturally synced, because ape send update to all connected windows... when you open new Windows, your history is limited to the time when you open this Windows. standard and efficient.. why to do more complex ?. think simple. did you see tron 2 .? perfection is evil.. Le jeudi 18 septembre 2014 21:29:44 UTC+2, Happy Meeple a écrit : > Thanks both for your replies. > > As an exemple, I fetch a chat history when opening a new window. When I > open a second window, it loads the history again in the first window. > Obviously, this is easy to correct, I can check that the history has never > been received before creating the elements. But I wasn't so far and the > unexpected result was that the history was loaded twice. Moreover, as the > created divs had the same names, the custom elements that I also generate > for each line (like the number of likes of the message) were only updated > on the first history list not the second one (and the second one was left > in a weird state with empty rectangles). A big mess! > > Long story short. There is a workaround in that case, and there will be in > most cases I am sure. But I don't want to have to think about this for > every single case. There will be unexpected results again I am sure. And it > could be really bad. > > That's why I am looking for a systematic solution. > > If I were less tired, I would probably have already found it. But I have > worked too much these days :) > > > > > > > > > > Nicolas Guibert > > Games in Mind Ltd > > Managing director > > 7 Spencer Walk > London NW3 1QZ > > Tel: +44 (0)207 435 0315 > > UK Mobile: +44 (0)7438 657 537 > > French Mobile: +33 (0)7 53 17 20 13 > > > Email: [email protected] <javascript:> > > > > 2014-09-18 19:53 GMT+01:00 audebert christian <[email protected] > <javascript:>>: > >> Just a question. >> >> Is it really significant to prevent user to open more windows with same >> session.?? >> >> As Microsoft said, it isn’t a bug, it’s functionality J >> >> If you absolutely want to prevent multiples windows from same sessions, >> you can, using some counter hidden in javascript for exemple, but, it will >> be extremely hard to do this safe and convenient way.. >> >> Exemple. What happens if I want to see datas from a windows, and use them >> to other windows.?? If I follow your need, I can’t.. >> >> Or, what happens if I use F5 to refresh my windows.?? It’s same session, >> but other new windows.. >> >> you have to manage some heavy and difficult cases, it’s worth the effort.? >> >> Or simply assume that your users have multiples windows with same >> session. In this case, with ape, you have the tool to synchronize each >> windows with datas updates.. >> >> And, simply close window that are no longer useful for exemple.. >> >> >> >> *De :* [email protected] <javascript:> [mailto: >> [email protected] <javascript:>] *De la part de* Louis Charette >> *Envoyé :* jeudi 18 septembre 2014 18:18 >> *À :* [email protected] <javascript:> >> *Objet :* Re: [APE Project] single instance - prevent multiple windows - >> block second window >> >> >> >> I can't access the link on my phone, but on the client side you can use >> the JOIN event. When you don't use sessions, If the same user connects >> you'll get a new event fired. You can check manually if it's the same >> person (by ip, username or other custom properties) and redirect using >> JavaScript or whatever. When using sessions there must be some sort of >> event too (I never actually used sessions) >> >> >> >> - Louis >> >> Envoyé de mon iPhone >> >> >> Le 2014-09-18 à 06:29, Nicolas <[email protected] <javascript:>> a >> écrit : >> >> Hi, >> >> >> >> I wonder how you would prevent a user from opening a second window with >> APE? Obviously there are reasons why it is easier to make sure that there >> is only one window open. >> >> >> >> There was a thread about this a while ago. I am sure if the solution >> proposed by efyx was implemented on the server side. If anybody knows let >> me know? >> >> >> >> >> https://groups.google.com/forum/#!searchin/ape-project/multiple$20windows/ape-project/unmh0Tblsng/m2OTL5F8pDwJ >> >> >> >> Thanks. >> >> >> >> Nicolas. >> >> >> >> >> >> -- >> -- >> You received this message because you are subscribed to the Google >> Groups "APE Project" group. >> To post to this group, send email to [email protected] >> <javascript:> >> To unsubscribe from this group, send email to >> [email protected] <javascript:> >> For more options, visit this group at >> http://groups.google.com/group/ape-project?hl=en >> --- >> APE Project (Ajax Push Engine) >> Official website : http://www.ape-project.org/ >> Git Hub : http://github.com/APE-Project/ >> >> --- >> You received this message because you are subscribed to the Google Groups >> "APE Project" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> For more options, visit https://groups.google.com/d/optout. >> >> -- >> -- >> You received this message because you are subscribed to the Google >> Groups "APE Project" group. >> To post to this group, send email to [email protected] >> <javascript:> >> To unsubscribe from this group, send email to >> [email protected] <javascript:> >> For more options, visit this group at >> http://groups.google.com/group/ape-project?hl=en >> --- >> APE Project (Ajax Push Engine) >> Official website : http://www.ape-project.org/ >> Git Hub : http://github.com/APE-Project/ >> >> --- >> You received this message because you are subscribed to the Google Groups >> "APE Project" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> For more options, visit https://groups.google.com/d/optout. >> >> -- >> -- >> You received this message because you are subscribed to the Google >> Groups "APE Project" group. >> To post to this group, send email to [email protected] >> <javascript:> >> To unsubscribe from this group, send email to >> [email protected] <javascript:> >> For more options, visit this group at >> http://groups.google.com/group/ape-project?hl=en >> --- >> APE Project (Ajax Push Engine) >> Official website : http://www.ape-project.org/ >> Git Hub : http://github.com/APE-Project/ >> >> --- >> You received this message because you are subscribed to the Google Groups >> "APE Project" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> For more options, visit https://groups.google.com/d/optout. >> > > -- -- You received this message because you are subscribed to the Google Groups "APE Project" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/ape-project?hl=en --- APE Project (Ajax Push Engine) Official website : http://www.ape-project.org/ Git Hub : http://github.com/APE-Project/ --- You received this message because you are subscribed to the Google Groups "APE Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
