码迷,mamicode.com
首页 > 移动开发 > 详细

iOS js

时间:2017-04-07 10:17:10      阅读:242      评论:0      收藏:0      [点我收藏+]

标签:login   eval   device   orm   tde   elf   uidevice   ber   get   

[webView stringByEvaluatingJavaScriptFromString:@"document.getElementById(\"idNumber\").value=\"6217000x10055975513\";"];

    [webView stringByEvaluatingJavaScriptFromString:@"document.getElementById(\"username\").value=\"于淇\";"];

 

NSString *username = [webView stringByEvaluatingJavaScriptFromString:@"document.getElementById(\"username\").value;"];

    NSString *account = [webView stringByEvaluatingJavaScriptFromString:@"document.getElementById(\"idNumber\").value;"];

 

CGFloat height = [[webView stringByEvaluatingJavaScriptFromString:@"document.getElementsByClassName(‘tips-login‘)[0].offsetHeight"] floatValue];

    

    [webView stringByEvaluatingJavaScriptFromString:@"document.getElementsByClassName(‘tips-login‘)[0].style.margin=\"0.3rem 3.5rem 0 3.5rem\""];

 

 

 

NSString *info = [[UIDevice currentDevice] name];

        NSString *js = [NSString stringWithFormat:@"showInfo(\"name\",\"%@\")",info];

        NSString *jx = [self.webView stringByEvaluatingJavaScriptFromString:js];

 

iOS js

标签:login   eval   device   orm   tde   elf   uidevice   ber   get   

原文地址:http://www.cnblogs.com/feng9exe/p/6676247.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!