简体   繁体   English

2页之间实时同步

[英]Real-time Sync between 2 pages

I have a project that I am trying to find a solution for. 我有一个项目正在寻找解决方案。 I am attempting to have an Element (maybe a DIV), between 2 pages, be synchronized in real-time. 我正在尝试使2页之间的Element(也许是DIV)实时同步。 After doing some research, it looks like using WebSocket to link them might be the best solution. 经过一些研究,看起来使用WebSocket链接它们可能是最好的解决方案。 I'm not experienced with setting up a scenario like this so have been trying to wrap my head around it. 我没有设置这样的场景的经验,所以一直试图把它包裹住。

My ultimate goal is to be able to inject (via JQuery) code into the shared/synced div (iframes with PDFs, URLs, other files) that will show up without refreshing on the 2nd page, real-time, so it works almost like co-browsing, but only a section of the page. 我的最终目标是能够(通过JQuery)将代码注入到共享/同步的div(带有PDF,URL,其他文件的iframe)中,而不会在第二页上实时刷新,因此它的工作原理类似于共同浏览,但只有页面的一部分。

I'm building my app with ASP.NET MVC4/Razor. 我正在使用ASP.NET MVC4 / Razor构建我的应用程序。

Any suggestions or pointers in the right direction would be greatly appreciated! 任何建议或正确方向的指针将不胜感激!

如果使用ASP.NET, SignalR可能是一个解决方案。

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

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