12345678910111213141516171819202122 |
- //
- // WKWebView_XF.swift
- // xingchuangke
- //
- // Created by uen on 2020/7/24.
- // Copyright © 2020 Virgil. All rights reserved.
- //
- import Foundation
- import WebKit
- public extension WKWebView {
- func loadDataForUrl(url: String) {
- if url == "" {
- return
- }
- let urlNew = CommonURL.formatURL(url)
- if urlNew != nil {
- self.load(NSURLRequest(url: NSURL(string: urlNew!)! as URL, cachePolicy: .reloadIgnoringLocalCacheData, timeoutInterval: 15) as URLRequest)
- }
- }
- }
|