PhoneGap 和内容管理系统集成
我正在尝试遍历整个 PhoneGap 事物来启动并运行本机应用程序。我完全可以为实际应用程序创建 html5 标记,我需要帮助的是尝试从网站中提取动态内容。特别是,我们网站上的一些内容也需要包含在应用程序中。我们使用一个名为“表达式引擎”的程序来处理我们的所有内容。我需要拉取的内容是:
- 讲道视频
- 讲道系列
- 位置
- 纯文本内容
该应用程序的大部分内容将是本地的,但正如您所看到的,也有一些动态需求。我读过几篇文章,说“JSON”是可行的方法,但它看起来相当复杂,因为我不太熟悉 AJAX。这是唯一的方法吗?或者任何人都可以向我指出可能有帮助的选项或资源。我什至不确定该方法是否适用于我们的网站。我感谢您能提供的任何帮助。
I'm trying to traverse the whole PhoneGap thing to get a native app up and running. I am completely fine with creating html5 markup for the actual app, what I need help with is trying to pull in dynamic content from a website. In particular, there is some content on our website that also needs to be in the app. We use a program call Expression Engine that handles all of our content. The content that I would need to pull over would be:
- Sermon Videos
- Sermon Series
- Locations
- Plain text content
The majority of the app will be local, but there are some dynamic needs as you can see. I've read a couple things that say "JSON" is the way to go, but it looks pretty complicated as I'm not quite familiar with AJAX. Is this the only way or are there any options or resources anyone can point me to that might help. I'm not even sure if that method would work for our website. I appreciate any help you can provide.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
他们是正确的。您需要研究的是 AJAX/JSON 以及如何使用这些技术将数据呈现给您的应用程序。
表达式引擎实际上是一个很好的选择,因为它的模板系统非常灵活。如果您不想走这条路,甚至还有附加模块可以将您的内容作为 JSON 提供。
快速谷歌引导我到: http ://samcroft.co.uk/2011/updated-loading-data-in-phonegap-using-jquery-1-5/
这比您需要的要多一点,因为您将拥有自己的内容在现有的 CMS 中,而不是创建一个新的数据库来存储数据,但这些概念将是正确的,我相信您将能够使用它来找到更多更适合您的教程。
They are correct. What you need to look into is AJAX/JSON and how to present your data to your app using these technologies.
Expression Engine would actually be quite a good choice for this as its template system is quite flexible. There are even add-on modules for delivering your content as JSON if you want t go that route.
A quick google led me to: http://samcroft.co.uk/2011/updated-loading-data-in-phonegap-using-jquery-1-5/
It's a bit more than you need since you will have your content in an existing CMS instead of creating a new database to store the data, but the concepts will hold true and I am sure you will be able to use it to find more tutorials that suit you better.