
內容簡介
Advanced Footnotes 讓您通過短代碼在文章中添加註腳。Advanced Footnotes 非常可定制,因此可以在任何佈景主題上實現它。
憑藉其內部功能,您還可以以任何形式在自己的佈景主題上實現 Advanced Footnotes。
主要功能:
- 易於實現及靈活可自訂。
- 實現了所見即所得編輯器按鈕。
- 註腳可以使用短代碼或功能實現。
- 帶動畫捲動效果(可以禁用)
- 輕量級 CSS(可以禁用)
- 自訂 CSS 樣式
- 動態可更改的界面選項(JS 可以完全禁用)
使用方法:
插入註腳:
要插入註腳,您可以使用新增於您所見即所得編輯器中的“新增註腳”按鈕,或使用 [footnote]您的註腳[/footnote] 短代碼。
短代碼參數:
“type”: 確定參考類型。選項: 數字/非數字。
列舉註腳:
您可以使用兩種方法顯示註腳:
短代碼列舉:
只需在您的文章內容中插入 [footnotes] 短代碼,即可在文章中任何位置顯示註腳。
短代碼參數:
“title”: 確定註腳列表的標題。可以通過插件設置設置默認值。
短代碼用法:
[footnotes title="My Custom Footnotes Title"]
// 或
[footnotes title="false"]
通過主題引入列舉:
可以通過調用 advanced_footnotes 類的 print_refs 函數來打印註腳。
簡單的功能用法:
call_user_func(array('advanced_footnotes', 'print_refs'));
其他參數:
第一個參數:“Print”,是打印還是返回註腳內容。 (默認值:“true”)
第二個參數:“Title”,確定註腳內容的標題。(默認值:“false”)
帶參數的函數用法:
$footnotes = call_user_func_array(array('advanced_footnotes', 'print_refs'), array(false, 'Custom Footnotes Title'));
插件選項:
可以通過“選項/Advanced Footnotes”訪問插件選項。
- 包含插件 CSS:確定是否包含默認的插件 CSS 文件。如果要在主題內重新設計插件,請禁用此選項。
- 自定義 CSS:提供一個自定義 CSS 樣式的字段。
- 包含插件 JS:確定是否在主題輸出中包含插件 javascript 文件。如果要自定義插件互動或僅使用本地 HTML 錨定點,請禁用此選項。
- 註腳默認標題:設置“[footnotes]”短代碼使用的默認標題。
- 註腳符號:設置非數字註腳使用的符號。
- 禁用 JS 選項:確定是否將選項應用於插件 JS 文件。
- 註腳捲動間隙:點擊註腳時設置捲動邊距。當您有一個固定的標題或任何其他阻礙窗口區域的元素時,請設置此選項。
- 註腳捲動速度:設置單擊註腳時的動畫速度。設置為 0 表示沒有動畫。
HTML 結構和類:
錨點:
數字錨點:
```html
{number - automatically incremented}
```
非數字錨點:
```html
{your reference}
```
註腳列表:
```html
{title}
{number}{footnote text}
```
外掛標籤
開發者團隊
原文外掛簡介
Advanced Footnotes lets you add footnotes on articles via shortcodes. Advanced Footnotes is is extremely customizable, therefore it can be implemented on any theme.
With its internal functions, you can also implement Advanced Footnotes on your own theme in any form you like.
Main Features:
Easy & flexible implementation.
Implemented WYSIWYG editor button.
Footnotes can be implemented with shortcode or function.
Animated scroll effect (can be disabled)
Lightweight CSS (can be disabled)
Custom CSS styling
Dynamically changeable interface options (JS can be fully disabled)
Usage
Inserting a Footnote:
In order to insert a footnote, you can either use the “Insert Footnote” button added on your WYSIWYG editor, or use the [footnote]your-footnote-here[/footnote] shortcode.
Shortcode Parameters:
“type”: Determines the type of the reference. Options: numeric / non-numeric.
Listing Footnotes:
You can display the footnotes in two methods:
Listing by Shortcode:
By simply inserting the [footnotes] shortcode in your post content, you can display footnotes wherever you want in your posts.
Shortcode Parameters:
“title”: Determines the title for the footnotes list. Default value can be set through plugin settings.
Shortcode Usage:
[footnotes title="My Custom Footnotes Title"]
// or
[footnotes title="false"]
Listing by Theme Inclusion:
You can print the footnotes by calling print_refs function from the advanced_footnotes class.
Simple Function Usage:
call_user_func(array('advanced_footnotes', 'print_refs'));
Additional Parameters:
First parameter: “Print”, whether print or return the footnotes content. (Default: “true”)
Second parameter: “Title”, determines the title for the footnotes content. (Default: “false”)
Function Usage with Parameters:
$footnotes = call_user_func_array(array('advanced_footnotes', 'print_refs'), array(false, 'Custom Footnotes Title'));
Plugin Options:
You can access the plugin options through “Options/Advanced Footnotes”.
Include Plugin CSS: Determines whether to include the default plugin css files. Disable this if you want to re-style the plugin within your theme.
Custom CSS: Provides a field for custom CSS styling.
Include Plugin JS: Determines whether to include the plugin javascript files on the theme output. Disable this if you want to customize plugin interactions or just to use native HTML anchors.
Default Title for Footnotes: Sets the default title used on the “[footnotes]” shortcode.
Footnote Symbol: Sets the symbol used for non-numeric footnotes.
Disable JS Options: Determines whether to apply options to the plugin JS files or not.
Footnotes Scroll Gap: This sets the scroll margin when clicked on a footnote. Set this when you have a fixed header or any other element blocking some part of the window area.
Footnote Scroll Speed: Sets the animation speed when a footnote is clicked. Set 0 for no animation.
HTML Structure & Classes
Anchors:
Numeric Anchor:
{number - automatically incremented by the order}
Non-numeric Anchor:
footnote symbol
References:
Non-numbered references are listed before the numbered references on the list.
Known Issues
WYSIWYG Button doesn’t work on the plugin TinyMCE Advanced (and probably on some other -WYSIWYG editor modifying- plugins).
Contribution
https://github.com/yutonet/wp_advanced_footnotes
