上次更新时间: 二月 12, 2025
We use cookies to improve HubSpot’s site. Some cookies are necessary for our website and services to function properly. Other cookies are optional and help personalize your experience, including advertising and analytics. You can consent to all cookies, decline all optional cookies, or manage optional cookies. Without a selection, our default cookie settings will apply. You can change your preferences at any time. To learn more, check out our Cookie Policy.
上次更新时间: 二月 12, 2025
HubSpot 托管内容默认使用自动调整图片大小功能。这样可以优化图片,使其适合在屏幕上浏览,从而缩短浏览器加载时间,提高 Google PageSpeed 分数。任何在 <img> 标记中定义了高度和宽度属性的图片都将被调整大小。
请注意:高度或宽度超过 4096 像素的图片不会自动调整大小。
您可以在 HTML 代码的图像 URL 中添加以下查询参数,禁用单个图像的自动图像大小调整功能:
?noresize
例如,由于高度和宽度属性是在 HTML 的 <img> 标签中设置的,因此以下图片将在页面上调整大小:
<img src="http://cdn2.hubspot.net/hub/211045/file-377800313-jpg/IMG_4134.jpg" height="500px" width="600px">
要禁用自动调整图片大小的功能,只需在图片 URL 中添加 ?noresize 参数即可:
<img src="http://cdn2.hubspot.net/hub/211045/file-377800313-jpg/IMG_4134.jpg?noresize" height="500px" width="600px">
在文件工具中手动调整图片大小: