开发者

in a xcode webview: how to get the name or id of input tag selected?

开发者 https://www.devze.com 2023-04-09 04:10 出处:网络
Inside an xcode application, I have an webview with a variable number of text input. There is a method to get to xcode the attribute \"name\" or \"id\" when I selected the field?

Inside an xcode application, I have an webview with a variable number of text input.

There is a method to get to xcode the attribute "name" or "id" when I selected the field?

My problem is that 开发者_StackOverflow社区I don't know how to pass the name or id of selected field to xcode.


Check this out :

NSString *string = 
   [webView stringByEvaluatingJavaScriptFromString:@"document.getElementById('your_id_here');"];  
0

精彩评论

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