[WordPress] 外掛分享: Post Head Includes

WordPress 外掛 Post Head Includes 的封面圖片。

前言介紹

  • 這款 WordPress 外掛「Post Head Includes」是 2013-05-13 上架。
  • 目前有 10 個安裝啟用數。
  • 上一次更新是 2013-08-25,距離現在已有 4568 天。超過一年沒更新,安裝要確認版本是否可用。以及後續維護問題!
  • 尚未有人給過這款外掛評分。
  • 還沒有人在論壇上發問,可能目前使用數不多,還沒有什麼大問題。

外掛協作開發者

rbuczynski |

外掛標籤

css | javascript | wp_enqueue_style | wp_enqueue_script | post-head-includes |

內容簡介

這個外掛能夠輕鬆地在每篇文章中加入腳本和樣式表。這是開發人員為其客戶創建自定義頁面的優秀工具,同時也適用於博主將內聯 CSS 和 JS 與其文章內容分離的需求。

這個外掛提供了wp_enqueue_script與wp_enqueue_style函數的介面,因此這個外掛具備了開發人員在它們原先使用的所有功能。

然而,這個外掛不同於wp_localize_script的腳本本地化功能,因為在這個外掛中,您可以輸入原始的JavaScript代碼,用於腳本本地化、庫初始化等。

此外,這個外掛還可以幫助解決現代瀏覽器的XSS檢測可能會阻止潛在不安全JavaScript的問題。

原文外掛簡介

Easily add scripts and stylesheets per post. This is a great tool for developers creating custom pages for their clients, but also useful for the blogger who wants to separate inline CSS & JS from their post content.
This plugin provides an interface for wp_enqueue_script and wp_enqueue_style functions, so all of the functionality that a developer would find there is available in this plugin.
However, script localization differs from wp_localize_script in that with this plugin you are allowed to input raw JavaScript code for localization, library initialization, and more.
This plugin may also help to alleviate modern browser XSS detection from blocking potentially unsafe JavaScript.

各版本下載點

  • 方法一:點下方版本號的連結下載 ZIP 檔案後,登入網站後台左側選單「外掛」的「安裝外掛」,然後選擇上方的「上傳外掛」,把下載回去的 ZIP 外掛打包檔案上傳上去安裝與啟用。
  • 方法二:透過「安裝外掛」的畫面右方搜尋功能,搜尋外掛名稱「Post Head Includes」來進行安裝。

(建議使用方法二,確保安裝的版本符合當前運作的 WordPress 環境。


0.1.0 | 0.2.0 |

延伸相關外掛(你可能也想知道)

  • Speed Up – Optimize CSS Delivery 》這個小外掛(5 Kb)可以異步載入樣式表並提高頁面載入速度。, 建議使用此外掛程式來同步載入重要的樣式表和異步載入非關鍵的 CSS 檔案。, 非關鍵的 CSS 檔案...。
  • Debug Bar List Script & Style Dependencies 》我們都知道在 WordPress 中添加 script 或 style 時,我們應該使用 wp_enqueue_script( $handle, $src, $deps, $ver, $in_footer ) 和 wp_enqueue_style( $ha...。

文章
Filter
Apply Filters
Mastodon