在IOS 10中使用web视图控件时,如何隐藏页眉和页脚(灰色框)?我使用的是拖到视图控件上的UIWebView。web视图在放置到情节提要时具有灰色方框。我在以前的版本中使用过web视图,没有看到这些框。
发布于 2017-01-29 03:54:39
您可以尝试以编程方式设置web视图:
webView = WKWebView(frame: CGRect(x: 0, y: 0, width: self.view.frame.width, height: self.view.frame.height), configuration: null)
let url = URL(string: "http://www.google.com")
let urlRequest = URLRequest(url: url!)
webView.load(urlRequest)
self.view = webView
https://stackoverflow.com/questions/41911842
复制相似问题