我们可以将“phonegap api”应用程序与纯本地应用程序(obj-C)代码连接 [英] Can we connect 'phonegap api ' application with pure native application(obj-C) code

查看:114
本文介绍了我们可以将“phonegap api”应用程序与纯本地应用程序(obj-C)代码连接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在做一个项目。
第一页应该是网页r'phonegap api'html page。

I am doing a project. The first page should be the web page r 'phonegap api' html page.

当一个简单的链接r按钮被点击,它应该被带到原生应用程序,纯obj C,纯原生应用程序(具有视图控制器,表视图等)。

when a perticular link r button is tapped , it should be taken to the native Application,purely obj C,Pure native App(with view controllers, table views etc).

我们可以将HTML页面与纯本地代码连接吗?如果是,那么Plz告诉我如何?

Can we connect the html page with the pure native code? If yes, Then Plz tell me how?

提前感谢,

Bharath gangpalli

Bharath gangpalli

推荐答案

您可以创建一个PhoneGap插件,它是PhoneGap API的自定义扩展。它包括一些本地代码,它具有一些特定于本地的功能,以及一个JavaScript接口,然后向您展示这个功能,PhoneGap开发人员。根据定义,插件是特定于平台的!

You could create a PhoneGap plug-in, which is a custom extension to the PhoneGap API. It includes a bit of native code that does some native-specific functionality, as well as a JavaScript interface that then exposes this functionality to you, the PhoneGap developer. By definition, a plug-in is platform-specific!

在您的情况下,您可以创建一个插件,然后将新的视图推送到应用程序的顶部(例如HTML页面上的覆盖)。

In your case, you could create a plug-in that then pushes a new View to the top of the app (overlays over the HTML page, for example).

一个好的开始的地方是Jesse的博客文章;请注意,这些是专门为iPhone:

A good place to start would be Jesse's blog post about them; note that these are specifically for iPhone:

http://blogs.nitobi.com/jesse/2010/04/01/iphonegap-plugs/

以下是现有PhoneGap的一些示例插件,如何使用它们,以及到源代码中的链接,以了解它们是如何构建的:

Here are some examples of existing PhoneGap plugins, how to use them, and links within to the source code to see how they were built:

https://github.com/phonegap/phonegap-plugins

http://blogs.nitobi.com/shazron/2010/07/12/phonegap-iads-plugin/

http://blog.urbanairship.com / blog / 2010/06/09 / phonegap-push /

http://blog.clearlyinnovative.com/post/1097750723/phonegap-plugin-for-downloading-url

这篇关于我们可以将“phonegap api”应用程序与纯本地应用程序(obj-C)代码连接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆