func setWeb(){
var web:UIWebView=UIWebView.init(frame: CGRect.init(x: 0, y: 0, width: WIDTH, height: HEIGHT-64))
if HEIGHT==812{
web=UIWebView.init(frame: CGRect.init(x: 0, y: 0, width: WIDTH, height: HEIGHT-88-34))
}
view.addSubview(web)
web.delegate=self
let urlStr:String="http://erhaoqianbao.a.akzngj.com/#/card"
let url:NSURL=NSURL.init(string: urlStr)!
let rquest:NSURLRequest=NSURLRequest.init(url: url as URL)
web.loadRequest(rquest as URLRequest)
}
//加载完成
func webViewDidFinishLoad(_ webView: UIWebView) {
}
//加载失败
func webView(_ webView: UIWebView, didFailLoadWithError error: Error) {
}
//允许加载网页true,false不允许,在其中可以
func webView(_ webView: UIWebView, shouldStartLoadWith request: URLRequest, navigationType: UIWebViewNavigationType) -> Bool {
}