[WordPress] 外掛分享: Widget Context

WordPress 外掛 Widget Context 的封面圖片。

前言介紹

  • 這款 WordPress 外掛「Widget Context」是 2009-07-15 上架。
  • 目前有 40000 個安裝啟用數。
  • 上一次更新是 2024-08-31,距離現在已有 246 天。
  • 外掛最低要求 WordPress 3.0 以上版本才可以安裝。
  • 外掛要求網站主機運作至少需要 PHP 版本 5.6 以上。
  • 有 96 人給過評分。
  • 還沒有人在論壇上發問,可能目前使用數不多,還沒有什麼大問題。

外掛協作開發者

kasparsd | jamescollins |

外掛標籤

logic | widget | context | widgets | widget context |

內容簡介

使用 Widget Context 外掛在網站的特定部分 (如首頁、文章、頁面、檔案、搜尋等) 中顯示或隱藏小工具。該外掛可支援使用 URL 定位來達到最大的彈性。

高級支援

訂閱我們的高級支援服務,當 PRO 🚀 版本推出時,您將免費獲得該插件版本!您的支援能夠讓插件持續維護和開發新的功能,我們非常感激。

貢獻

在Github上提供程式碼改進建議。
在WordPress.org論壇上回報錯誤或提出建議。
幫忙翻譯插件到您的語言。

文檔

小工具的可見性可以在 WordPress 管理區的「外觀 → 小工具」中的單獨小工具設置或在自訂器中的小工具編輯界面中進行配置。

按 URL 定位

「按 URL 定位」是一個強大的功能,可以根據請求 URL 定位網站的各個部分。它受到Drupal CMS類似功能的啟發。

使用相對 URL,例如page/sub-page,而不是絕對 URL https://example.com/page/sub-page,因為相對 URL 更加靈活,可以在不同的域和環境之間移植邏輯。

萬用字符

使用萬用字符*來匹配 URL 的動態部分。例如:

topic/widgets/* 可以匹配小工具類別中的所有文章,如果您的永久鏈接結構設置為/topic/%category%/%postname%,則這樣寫。

page-slug/* 可以匹配父頁面為 page-slug 的所有子頁面。

使用尾隨的?*來捕獲 URL 的所有查詢引數,例如utm_source等。例如,對於每個blog/post-slug,還包括blog/post-slug?*。

排除 URL

指定URL以忽略,即使它們被其他上下文規則匹配也是如此。例如,輸入example/sub-page即可在全局區域下選擇「所有文章」時隱藏該頁面的小工具。

原文外掛簡介

Use Widget Context to show and hide widgets on certain sections of your site — front page, posts, pages, archives, search, etc. Use targeting by URLs (with wildcard support) for maximum flexibility.

Premium Support
Subscribe to our Premium Support service and get the PRO 🚀 version of the plugin for free when it’s launched! Your support enables consistent maintenance and new feature development, and is greatly appreciated.
Contribute

Suggest code improvements on GitHub.
Report bugs and suggestions on WordPress.org forums.
Help translate to your language.

Documentation
Widget visibility can be configured under individual widget settings under “Appearance → Widgets” in your WordPress administration area or through the widget editing interface in the Customizer.
Target by URL
The “Target by URL” is a powerful feature for targeting sections of your website based on the request URLs. It was inspired by a similar feature in the Drupal CMS.
Use relative URLs such as page/sub-page instead of absolute URLs https://example.com/page/sub-page because relative URLs are more flexible and make the logic portable between different domains and server environments.
Wildcards
Use the wildcard symbol * for matching dynamic parts of the URL. For example:

topic/widgets/* to match all posts in the widgets category, if your permalink structure is set to /topic/%category%/%postname%.

page-slug/* to match all child pages of the page-slug parent page.

Use a trailing ?* to capture URL with all query arguments such as utm_source, etc. For example, for every blog/post-slug also include blog/post-slug?*.

Exclude by URL
Specify URLs to ignore even if they’re matched by any of the other context rules. For example, enter example/sub-page to hide a widget on this page even when “All Posts” is selected under “Global Sections”.

各版本下載點

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

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


0.6 | 0.7 | 0.8 | 1.0 | 0.4.1 | 0.4.2 | 0.4.3 | 0.4.4 | 0.4.5 | 0.7.1 | 0.7.2 | 0.8.1 | 0.8.2 | 0.8.3 | 1.0.1 | 1.0.2 | 1.0.3 | 1.0.4 | 1.0.5 | 1.0.6 | 1.0.7 | 1.1.0 | 1.1.1 | 1.2.0 | 1.3.0 | 1.3.1 | 1.3.2 | 1.3.3 | trunk |

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

  • Loops & Logic 》Facebook group | homepage| docs |official support forum, Loops & Logic 是一個工具集,讓你可以對 WordPress 內容和數據在網站前端進行廣泛的控制,...。
  • HumanCaptcha by Outerbridge 》大部分的驗證碼需要輸入一些隨機生成的字符(有時模糊不清,擺動或者在模糊的背景下)的要求。HumanCaptcha 則生成一個需用邏輯思考回答的簡單問題。HumanCap...。
  • Restaurant Logic 》餐廳邏輯(Restaurant Logic)外掛需要與有效的餐廳邏輯帳戶搭配使用。餐廳邏輯是任何餐廳網站的#1行銷工具。, 可用功能, , 適用於行動裝置的工作應用程式, ...。
  • Theme Logic 》此外掛已被棄用。。
  • Logic Shortcodes 》這個外掛讓你可以使用 [if] 簡碼來進行條件邏輯判斷,判斷依據可以是帖子或頁面上的分類或標注詞的存在情況。, 如果您願意,請考慮花一分鐘評價這個外掛或讓...。
  • DynoWidg 》此外掛允許您動態地將任何內容片段新增至側邊欄,並提供您基於 WordPress 條件式和/或選擇特定區域的限制頁面/區段的能力。, 請將任何錯誤或建議的改善提交至...。
  • Block Logic Controller 》總結:這個WordPress外掛根據設定的條件或條件來顯示和隱藏區塊。如果條件符合,根據選擇的動作來顯示或隱藏區塊。, , 問題與答案:, 1. 這個WordPress外掛的...。

文章
Filter
Apply Filters
Mastodon