简体   繁体   English

离线网站

[英]offline website

There is a requirement to have a offline website. 必须有一个脱机网站。 It is like when the connection is available the client or the browser on the PC will download contents required and when there is no internet the client will access be still available with the data which was downloaded earlier. 就像当连接可用时,客户端或PC上的浏览器将下载所需的内容,而当没有Internet时,客户端将仍然可以访问先前下载的数据。

During the discussion there was a suggestion to use http://code.google.com/apis/gears/ . 在讨论期间,有人建议使用http://code.google.com/apis/gears/

Kindly let me know what are all the other frameworks available to solve this problem. 请让我知道解决这个问题的所有其他可用框架。

as greg notes, gears indeed will be phased out by google, html5 is supposed to replace gears for offline webapps. 正如greg所指出的,齿轮的确确实会被Google淘汰,html5应该会取代离线webapp的齿轮。

most important specs: 最重要的规格:

  • " appCache " (to store files locally) appCache ”(用于在本地存储文件)
  • " localStorage " (to store strings) localStorage ”(用于存储字符串)
  • " webDB " (to store structured data, will not be official part of html5 though). webDB ”(用于存储结构化数据,尽管不是html5的正式组成部分)。

and some examples; 和一些例子;

HTML 5 will contain many of the features that were previously available in Gears. HTML 5将包含Gears先前提供的许多功能。 The Gears API Blog has an entry titled Hello HTML5 that explains more about this. Gears API博客中有一个标题为“ Hello HTML5”的条目,该条目详细介绍了此内容。 Google has stopped development on Gears itself and is concentrating their efforts on HTML 5. Google已停止对Gears本身的开发,并将精力集中在HTML 5上。

Silverlight (or I can guess Flash) also could be used as offile storage. Silverlight(或者我可以猜到Flash)也可以用作文件存储。 But as for me this is kind of overuse. 但是对我而言,这有点过度使用。 May be this is better to think about ligtwait desctop application. 考虑ligtwait desctop应用程序可能会更好。 Silverlight desktop mode? Silverlight桌面模式? Or Adobe Air? 还是Adobe Air?

Save yourself some time searching :-) --->> There are many already spun JavaScript libraries to make offline storage, and even syncing when online, easier. 节省您的搜索时间:-) --- >>有许多已经旋转的JavaScript库可以简化离线存储,甚至可以在线上进行同步。 A large list of existing libraries on this topic on github here . github上有关此主题的大量现有库。 Notice JayData (open source and commercially backed) PouchDB (open source and very active and has a sync when online feature). 注意JayData(开源和商业支持)PouchDB(开源,非常活跃,在线时具有同步功能)。 Other possible ones that look decent: TaffyDB, Store.js, Kizzy, BankersBox. 其他看起来不错的可能的例子:TaffyDB,Store.js,Kizzy,BankersBox。 As of this writing, I checked out each of the other ones not mentioned here and they are either old, very small or defunct - so hope I can save you some time. 在撰写本文时,我检查了这里未提及的其他所有对象,它们要么很旧,要么很小,要么已经不存在了-因此希望我能为您节省一些时间。 One other commercially based one is SequelSphere which is free for individual or commercially with 10 users or less. 另一种以商业为基础的产品是SequelSphere,它对于10个以下用户或个人免费提供。

Another option is to use server2go this can setup a stand alone web service with the website. 另一个选择是使用server2go,这可以在网站上设置独立的Web服务。 Then used in conjunction with an app called bitsync it could sync the offline and online data. 然后与名为bitsync的应用程序结合使用,可以同步脱机和在线数据。

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

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