Commit 98853e0c authored by 刘俊宏's avatar 刘俊宏

完成wk自适应

parent 370a6da7
......@@ -702,9 +702,10 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
cell.imgBtn.tag = indexPath.row
if goodsDesc.count > 0 {
cell.webView.isHidden = false
let headerString : String = "<header><meta name='viewport' content='width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no'><style>img{max-width:100%}</style></header>"
let goodsDescHmtl = "<html>" + goodsDesc + "</html>"
cell.webView.loadHTMLString(goodsDescHmtl, baseURL: nil)
cell.webView.loadHTMLString(goodsDescHmtl + headerString, baseURL: nil)
}
cell.imgBtn.setImage(UIImage(named: "tjxq"), for: .normal)
cell.btmH.constant = 25
......
......@@ -446,9 +446,10 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
cell.imgBtn.tag = indexPath.row
if goodsDesc.count > 0 {
cell.webView.isHidden = false
let headerString : String = "<header><meta name='viewport' content='width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no'><style>img{max-width:100%}</style></header>"
let goodsDescHmtl = "<html>" + goodsDesc + "</html>"
cell.webView.loadHTMLString(goodsDescHmtl, baseURL: nil)
cell.webView.loadHTMLString(goodsDescHmtl + headerString, baseURL: nil)
}
cell.imgBtn.setImage(UIImage(named: "tjxq"), for: .normal)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment