简体   繁体   English

如何在不刷新的情况下从外部页面更新内容div-GAE

[英]How to update content div from an external page without refreshing - GAE

Well, I'm developing an application in GAE with python and basically what I need is a way to emulate a chat in a many-to-one pages. 好吧,我正在使用python在GAE中开发一个应用程序,基本上我需要的是一种在多对一页面中模拟聊天的方法。 The many pages can send messages to the single page. 许多页面可以将消息发送到单个页面。

I looked for sockets but I get problems when I work with local ports (in all ports I tried I've got an access denied message), they only worked on console application and I need this working on web. 我在寻找套接字,但是在使用本地端口时遇到问题(在所有尝试访问拒绝的消息的端口中),它们仅在控制台应用程序上有效,我需要在网络上使用。 Then I looked for an AJAX solution but I can't still find that final part in which, after a message has been submitted, the content of the page that is going to receive all the messages has to be updated. 然后,我寻找了一个AJAX解决方案,但是我仍然找不到最终部分,在该部分中,提交了一条消息之后,必须更新将要接收所有消息的页面的内容。

Does anyone has an idea how to deal with this? 有谁知道如何处理吗? I'm also open to suggestions for a different implementation. 我也乐意接受其他实施方案的建议。

Have you looked at Google App Engine Channels ? 您是否看过Google App Engine频道? I think it is exactly what you are looking for: https://cloud.google.com/appengine/docs/python/channel/ 我认为这正是您要寻找的: https : //cloud.google.com/appengine/docs/python/channel/

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM