gpt4 book ai didi

iphone - UIWebview 中的 html 内的图像不正确

转载 作者:行者123 更新时间:2023-12-03 19:10:13 26 4
gpt4 key购买 nike

我想显示谷歌更新,网页有响应,但图像宽度未正确显示并超出边界。这是网页内容。

<div dir="ltr" style="text-align: left;" trbidi="on"><span id="docs-internal-guid-489c1670-b0dc-d32d-645e-eaf6ca555069"><span style="font-family: Verdana; font-size: 13.3333333333333px; font-weight: bold; vertical-align: baseline; white-space: pre-wrap;"><img alt="whats_new_doc_header_may2015LL.gif" height="112px;" src="https://lh5.googleusercontent.com/6RY9WSfX5yDRLKfl_Vp7GRQR1bFew_fO2rfOh7qcWrWwLvuaWtTxwIedwqvZJrQqGRPrlsJ-J3nlwrBGcEfhzDDwL_3yec8occvTSJTNeQVHNk4_tlmB-SQYfkqYkkJkRAJM64Q" style="-webkit-transform: rotate(0.00rad); border: none; transform: rotate(0.00rad);" width="624px;" /></span></span><br /><span style="font-family: Arial, Helvetica, sans-serif;">Check out the latest "What's New in Google Apps" </span><a href="https://goo.gl/RbYK9q" style="font-family: Arial, Helvetica, sans-serif;" target="_blank">newsletter</a><span style="font-family: Arial, Helvetica, sans-serif;"> [</span><a href="https://goo.gl/uepQTc" style="font-family: Arial, Helvetica, sans-serif;" target="_blank">pdf</a><span style="font-family: Arial, Helvetica, sans-serif;">] for a roundup of all Apps launches from May 2015.</span><br /><br /><a href="http://goo.gl/SUjIUI" style="font-family: Arial, Helvetica, sans-serif;" target="_blank">Newsletter Archive &amp; Translated Versions (coming soon for May issue)</a><br /><span style="font-family: Arial, Helvetica, sans-serif;"><br /></span><i><span style="color: #999999; font-family: Arial, Helvetica, sans-serif; font-size: x-small;"><br /></span></i><i><span style="color: #999999; font-family: Arial, Helvetica, sans-serif; font-size: x-small;">Note: all launches are applicable to all Google Apps editions unless otherwise noted</span></i><br /><br /><a href="http://whatsnew.googleapps.com/"><b>Launch release calendar</b></a><br /><a href="http://feedburner.google.com/fb/a/mailverify?uri=GoogleAppsUpdates&amp;loc=en_US"><b>Get these product update alerts by email</b></a><br /><a href="http://googleappsupdates.blogspot.com/atom.xml"><b>Subscribe to the RSS feed of these updates</b></a></div><img src="http://feeds.feedburner.com/~r/GoogleAppsUpdates/~4/5Saf-LdMFA4" height="1" width="1" alt=""/>

Portrait

Landscape

最佳答案

NSString *htmLData = @" ";//Write your all Response Here 

NSString *strTemplateHTML = [NSString stringWithFormat:@"<html><head> <style TYPE=\"text/css\"> img{max-width:100%;height:auto !important;width:auto !important;};</style></head><body style=\"margin:10; padding:0;\">%@</body></html>",htmLData];

[self.webView loadHTMLString:strTemplateHTML baseURL:nil];

关于iphone - UIWebview 中的 html 内的图像不正确,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30705703/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com