[WordPress] 外掛分享: BJ Lazy Load

首頁外掛目錄 › BJ Lazy Load
WordPress 外掛 BJ Lazy Load 的封面圖片
20,000+
安裝啟用
★★★★
4.2/5 分(90 則評價)
3031 天前
最後更新
問題解決
WordPress 3.5+ v1.0.9 上架:2011-12-05

內容簡介

延遲載入可使您的網站加載速度更快,並節省頻寬。

此外掛可取代您所有的文章圖片、文章縮略圖、大頭貼圖片和內容的 iframe,並使用佔位圖片,當訪客滾動頁面接近進入瀏覽器視窗時,再載入內容。也可用於文字小工具。

因為它適用於 iframe,因此也支援 YouTube、Vimeo 等的嵌入式視訊。

您也可以通過使用簡單的篩選器,將主題中的其他圖片和 iframe 進行延遲載入。

非 JavaScript 訪客將在 noscript 元素中獲取原始元素。

與 RICG Responsive Images 插件兼容,以呈現響應式圖片。

如果您有任何問題或建議,請告訴我。最快回覆方式是透過 Twitter:https://twitter.com/bjornjohansen

翻譯

俄語 (ru_RU),由 Elvisrk 翻譯
希伯來語 (he_IL),由 Imri Sagive 翻譯
波蘭語 (pl_PL),由 Maciej Gryniuk 翻譯
挪威博克馬爾語 (nb_NO),由 Bjørn Johansen 翻譯

此掛件的開發在 GitHub 進行,歡迎提交 pull requests。

選用用法

如果您在自訂範本中輸出圖片或希望延遲載入主題中的其他圖片,可以通過篩選器將 HTML 傳遞過去:

<?php
$img_html = '<img src="myimage.jpg" alt="">';
$img_html = apply_filters( 'bj_lazy_load_html', $img_html );
echo $img_html;
?>

開發人員注意:篩選器優先級為 10。

外掛標籤

開發者團隊

⬇ 下載最新版 (v1.0.9) 或搜尋安裝

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「BJ Lazy Load」→ 直接安裝(推薦)
📦 歷史版本下載

原文外掛簡介

Lazy loading makes your site load faster and saves bandwidth.
This plugin replaces all your post images, post thumbnails, gravatar images and content iframes with a placeholder and loads the content as it gets close to enter the browser window when the visitor scrolls the page. Also works with text widgets.
Since it works with iframes, it also covers embedded videoes from YouTube, Vimeo etc.
You can also lazy load other images and iframes in your theme, by using a simple filter.
Non-javascript visitors gets the original element in noscript.
Compatible with the RICG Responsive Images plugin for responsive images.
Please let me know if you have any issues. Fastest way to get a response is by Twitter: https://twitter.com/bjornjohansen
Translations

Russian (ru_RU) by Elvisrk
Hebrew (he_IL) by Imri Sagive
Polish (pl_PL) by Maciej Gryniuk
Norwegian Bokmål (nb_NO) by Bjørn Johansen

Development happens at GitHub. Pull requests are very welcome.
Optional usage
If you have images output in custom templates or want to lazy load other images in your theme, you may pass the HTML through a filter:
';
$img_html = apply_filters( 'bj_lazy_load_html', $img_html );
echo $img_html;
?>

Note for developers: The filter has a priority of 10.

延伸相關外掛

文章
Filter
Apply Filters
Mastodon