這個外掛並未在最新的 3 個 WordPress 主要版本上進行測試。開發者可能不再對這個外掛進行維護或提供技術支援,並可能會與更新版本的 WordPress 產生使用上的相容性問題。

Search & Index Page Content

外掛說明

If you are looking for a simple way to index the content of a long WordPress page or post, this plugin is your ticket.

Just like the “Content” quick-links on the right of every WordPress.org Codex page, this widget will automatically create a list of links to each header in the content of the pages you wish to index. You don’t need to create any anchor links for this to work.

By default, it also includes an on-page search form so that users can easily find anything on the page that is indexed.

The plugin is extremely light, unobtrusive and easy to use. It will only show up on sidebars of pages in which you use the [SIPC_Content] shortcode. This plugin will load jquery on pages that use the shortcode if you theme doesn’t already.

See a live demo here

Suggested Uses

  • Create simple FAQ pages without complex use of Custom Post Types.
  • Make your long posts easier to reference.
  • Leave a review to tell me how YOU used this plugin.

Languages

Available in Spanish and Serbian.

螢幕擷圖

安裝方式

  1. Upload the search-index-page-content folder to the /wp-content/plugins/ directory, or simply find and install it in WordPress under Plugins > Add New
  2. Activate the Search & Index Page Content plugin on the Plugins page in WordPress
  3. Slide the new Search & Index Page Content widget into a sidebar and pick your options.
  4. Edit the pages and posts you wish the widget to appear on by surrounding all their content with the [SIPC_Content] shortcode as such, and don’t forget to use the closing tag [/SIPC_Content]

常見問題集

I placed the widget in a sidebar but it won’t show up!

The widget is built to only show up on pages and posts for which the content has been surrounded by the [SIPC_Content] opening and closing shortcode tags as seen here:

[SIPC_Content]

All page / post content goes here.
Headers will be indexed and content will be searchable.

[/SIPC_Content]

The reason being that you most likely only have a few pages or posts that are long enough to deserve an index. Wouldn’t it be annoying if this widget showed up on every page and post, even short ones with no headers?

How does this plugin work? I used to manually create anchor links…

The plugin basically uses jquery (javascript) to search the content surrounded by the shortcode for headers and creates the links automatically each time the page is loaded. This all happens after the page is loaded, on the client side. The benefits are obvious: you no longer need to worry about updating anchor links manually, users get to reference long pages easily and the server doesn’t do any extra work.

使用者評論

2016 年 9 月 3 日
This is a great plugin, and much needed for those running site with lengthy post/page content. The index generation is smart! But the ability to query a single page, I feel, is the real value of this plugin. It would be significantly improved if it included the ability for user to see search results in linked list (like the index) and/or be able to jump through results on some kind of nav click. Really looking forward to future development of this project and possible shortcode option for placement of index/search outside of widget!
2016 年 9 月 3 日
Works great on a one page site with a very very long list of names and users will want to find their name in the list. Works like a dream
閱讀全部 3 則使用者評論

參與者及開發者

以下人員參與了開源軟體〈Search & Index Page Content〉的開發相關工作。

參與者

將〈Search & Index Page Content〉外掛本地化為台灣繁體中文版

對開發相關資訊感興趣?

任何人均可瀏覽程式碼、查看 SVN 存放庫,或透過 RSS 訂閱開發記錄

變更記錄

1.4

  • Now includes translation in Spanish provided by Andrew Kurtis at http://WebHostingHub.com/

1.3

  • Now includes translation in Serbian provided by Ogi Djuraskovic at http://FirstSiteGuide.com/

1.2

  • Added Localization and .pot file to enable translations

1.1

  • Bug fix of scrollTo

1.0

  • Initial realease of the plugin
  • Currently uses widget only, shortcode will be included in next version.