开发者

Detect Objective C event from PhoneGap

开发者 https://www.devze.com 2023-03-05 07:15 出处:网络
I want notification in phonegapwhen any event/method get call in Objective C code? Thanx in adv开发者_Go百科anceYou can invoke your Javascript logic from Objective C by calling \"stringByEvaluatingJa

I want notification in phonegap when any event/method get call in Objective C code?

Thanx in adv开发者_Go百科ance


You can invoke your Javascript logic from Objective C by calling "stringByEvaluatingJavascriptFromString" on the WebView object:

NSString* jsCallback = @"alert(\"Alert from Objective C!\");";
[webView stringByEvaluatingJavaScriptFromString:jsCallback ];
0

精彩评论

暂无评论...
验证码 换一张
取 消