How To Clear A UIWebView

Viewed 37275

I am very new to the whole programming business, and was wondering if there is any way to clear the contents of a UIWebView in iphone programming, so that the loading symbol for the next view is not showing up in front of the last view. Many Thanks, Thomas

6 Answers

Same answer in Swift 4.2, xCode 10

if let clearURL = URL(string: "about:blank") {
   myWebView.loadRequest(URLRequest(url: clearURL))
}
Related