外掛說明
一個為 WordPress 網站提供全功能 Markdown 語法的外掛,功能包含 Markdown 編輯器、即時預覽、圖片隨貼、[HTML 轉換成 Markdown] 協助程式等等。
詳細的文件請參閱 https://github.com/terrylinooo/githuber-md。
範例
影片中展示了下列步驟:
- 使用
HTML 轉換 Markdown
工具把 HTML 轉換為 Markdown 語法。 - 從 Photoshop 剪下圖片的選區範圍,然後把它貼到 Markdown 語法編輯器。
- Click “Update” button to save Markdown to
post_content_filtered
and save HTML topost_content
(it is what you will see in result). - 檢視結果。
外掛運作方式
- WP Githuber MD 將會儲存您的 Markdown 內容至
wp_posts
.post_content_filtered
欄位。 - 解析 Markdown 語為 HTML語法,儲存已解析的 HTML 到
wp_posts
.post_content
欄位。
This plugin will detect your Markdown content and decide what scripts will be loaded, to avoid loading unnecessary scripts.
For example, if you enabled Syntax highlight, you have to update your post again to take effects.
建議
使用這個外掛比較理想的情況是當您才剛開始經營一個新部落格的時候。
如果您打算使用這個外掛在現行部落格上,務必要:
- 停用其它的 Markdown 外掛,因為類似的外掛可能運作方式一樣,在送出文章時轉換格式。可能導至重複轉碼問題。
- 我的建議是停用草稿和自動存檔功能,選項在設定頁中。
特色
- Markdown 編輯器
- Live preview.
- 拼寫檢查
- 針對單一文章,啟用 / 停用 Markdown。
- 支援區塊編輯器。
- 支援自訂內容類型。
- Support Markdown extra syntax.
- [HTML 轉換成 Markdown] 工具。
- 圖片隨貼(支援上傳至 imgur.com 及 sm.ms 圖床)
- Highlight code syntax. (prism.js or hightlight.js)
- 流程圖。
- kaTeX 數學公式。
- 序列圖表。
- 美人魚 (圖表模組)
- MathJax 數學套件。
- 表情圖示套件。
- GitHub 定義的 Markdown 任務列表。
- Fetch remote images.
- 關鍵字建議工具。
- and more…
本地化人員
English (en_US) by Colocal.
Traditional Chinese (zh_TW) by Alex Lion.
Simplified Chinese (zh_CN) by Terry Lin.
版權
WP Githuber MD, Copyright 2018-2020 TerryL.in
WP Githuber MD is distributed under the terms of the GNU GPL
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
螢幕擷圖
安裝方式
- 將外掛安裝套件 ZIP 壓縮檔解壓縮所得的
wp-githuber-md
資料夾上傳至網站的/wp-content/plugins/
目錄中,或直接在 WordPress 的 [外掛] 選單中安裝外掛。 - 在 WordPress 管理後台的 [外掛] 選單中啟用外掛。
- 前往外掛下的 WP Githuber MD 選單來設定您的 Markdown 選項。
常見問題集
您可以在 回報問題 找到您的問題的解答。
使用者評論
參與者及開發者
變更記錄
= 1.0.0
- First release.
= 1.1.0
- Add Image-Paste module.
= 1.2.0
- Image paste – Provide an option that allows you directly upload to Imgur.com.
- Rename plugin name from “Githuber MD” to “WP Githuber MD”.
- Add new settings.
= 1.2.5
- Add support to WordPress 5.0 – Thanks to Classic Editor plugin.
= 1.3.0
- Add a
HTML to Markdown
tool beside editor. - Add an option that allows users to turn off
auto-save
. - Add more information in About page.
= 1.3.1
- Backward compatible with PHP 5.3 and WordPress 4.0.x. (Tested in PHP 5.3.5 with WordPress 4.0.25 OKAY.)
- Modify HTML-to-Markdown helper and image-paste description.
- Add language packs template.
- Improve HTML-to-Markdown helper.
= 1.3.2
- Add language pack: zh_TW.
- Fix bugs.
= 1.4.0
- Add Mermaid module.
- Add language pack: zh_CN.
- Fx bugs.
= 1.4.1
- Add line-number setting for Markdown Editor.
- Adjust KaTeX module – Now it can only used in the Markdown code blocks that are defined with
katax
. - Improve Markdown editor – Adjust the dialog button’s look and fix the overflow issues.
- Yoast SEO’s CSS has a global class name
path
uses animation, will break the Marmaid’s SVG in the editor’s preview panel, because they both uses the same common class name. We force to remove the animation attribute to make it work.
= 1.4.2
- Fix bug: HTML-to-Markdown helper.
= 1.4.3
- Bug fix – issue #3 – Thank to wojciehm@github for reporting this issue.
- Display a notice if user’s PHP version does not meet the minimum requirement.
= 1.5.0
- Detect Jetpack Markdown module.
= 1.5.2
- Fix bug: Inserting image not working. (issue #6)
- Support KaTex inline. (feature request #7)
- Add custom Markdown syntax block for HTML 5
figure
(feature request #8)
= 1.6.0
- Support cusotm post types.
- Add
Enable Markdown
option beside editor. - Support Gutenberg editor. Now you are able to disable Markdown for a post then back to use Gutenberg editor.
= 1.6.2
- Add a new setting option in ImagePaste module. (feature request #16)
- Add new option when using
Add media -> Insert to post
that allows user insert HTML into post. (feature request #17) - Fix bug: Classic editor’s visual mode is not showed after disabling post type option. (issue #15)
- Imporve: Beautify Markdown switcher.
= 1.7.0
- Improve setting page UI.
- Add examples in setting pages.
- Issue #22 – footnote.
- Feautue request #19 – Add support to shortcode.
- And other issues…
= 1.7.1
- Bug fix and a bit improvement.
= 1.7.2
- Fix issue: disable-revisions not working.
- Add donation information.
= 1.7.3
- Fix issues: #29, issue #30 and issue #31.
- Fix issue: Makrdown extra not working.
= 1.7.4
- Fix Javascript syntax error (Link Opening Method).
= 1.8.0
- Fix issue #39: Live-preview doesn’t react when Sync Scrolling is off.
- Feature request #36: Image-paste – add suport to sm.ms (another image hosting service)
- Fix bug: register_activation_hook does not implement when activating plugin at the first time.
- Fix issue: incorrect variable name in unstall.php.
= 1.8.1
- Fix issue: wp_get_attachment_url() doesn’t distinguish whether a page request arrives via HTTP or HTTPS
- Fix issue #38 – preserve inline code block.
- Add Simplified Chinese language package.
= 1.8.2
- Fix issue #42: Markdown syntax takes effect between two inline code blocks.
= 1.8.5
- Add feature: Githuber MD extensions – Inline code block with keyboard style. Example:
{ctrl}
- Fix issue: inline code block doesn’t work on just one character, for example
a
. This issue is associated with issue #42
= 1.8.6
- Fix issue #44: Unable to insert linked images.
- Fix issue #45: HTML-to-Markdown doesn’t transform table as expected.
= 1.9.0
- Add feature: TOC (Table of contents) module.
- Add feature: Transform
&
to&
in URLs.
= 1.9.1
- Fix issue #48: Because some systems don’t have
php_fileinfo
installed, use$_FILES['type']
instead.
= 1.10.0
- Feature request #53: Add
Copy-to-Clipboard
button on syntax highlighting code blocks. - Fix issue #52 – Remove auto-match highlighter.
- Fix issue #57 – Preserve code blocks in a list.
= 1.10.1
- Feature request #59: Move the front added .css and .js to the inline script section.
- Issue #62: Fix add media button that is invalid for other types of media files such as audio.
- Fix incorrect link coloring in marked.js
- Issue #49: Images are inserted at the end of the document.
= 1.11.0
- Feature request #65: Spell check.
- Add new settings in the Preferences tab.
= 1.11.1
- Fix issue #68: Cannot display javascript template text correctly on code blocks.
- Fix issue: TOC should not be displayed on homepage and archive pages.
- Improve: Spellcheck compatibility check.
- Improve: Allow Markdown syntax in code blocks.
= 1.11.2
- Fix issue #31 – This issue occurred again because of the modification of #57.
= 1.11.3
- Fix issue #70: Bug occurs when adding featured image.
- Fix issue #71: Support Shortcodes Ultimate plugin.
= 1.11.4
- Fix issue #72: Syntax highlight – use prism autoloader plugin instead.
- Feature request #74: Add an option for match highlighter.
= 1.11.5
- Jetpack compatibility #80, #81, thanks @jeherve
- Fix issue #92
- Remove donation information.
= 1.11.6
- Fix issue #89 – Code block parsing problems.
- Fix issue #96 – KaTex not working when using only inline syntax.
= 1.11.7
- Fix issue #99 – a CSS conflict in menu page.
- Fix issue #91 – post_id check.
- Feature request #98 – Add a new option in Preferences.
= 1.11.8
- Fix issue #107 – Fix parsing inline KaTax syntax.
- Fix issue #104 – UL list does not display correctly in the preview panel.
= 1.11.9
- Fix issue #126 – Conflict with WordPress 5.3 (
add_plugins_menu
function changes ) - PR #118 – Allow adding links to other file types rather than only inserting images.
= 1.12.0
- Feature request #75 – Save images to local folder.
- New feature – Syntax highlighter by highlight.js
- Hide
support comment
option because it doesn’t work now. - Update uninstall.php
= 1.12.1
- Move settings to the option submenu.
= 1.12.2
- Fix issue #144 – Deregistering
autosave
script gives error. (Fixed by alpipego. Thanks for contributing.) - Fix issue #143 – Unable to upload images to sm.ms. (The v1 API is deprecated.)
- Fix issue #147 – Update CodeMirror themes.
= 1.13.0
- New feature – MathJax.
= 1.13.1
- Bug fix – Missing property in Markdown class.
= 1.14.0
- Feature request #86, #135 – Emojify module.
- Fix issue #163 – Update KaTex version.
- Fix issue #127, #149 – Link opening method.
- Fix issue #156 – Highlight C code block.
- Fix issue #120 – FlowChart identification code – flow, which occurs a conflict to Prism.
- Fix issue #103 – Markdown editor UI – add support to zh_CN
= 1.15.0
- New feature – Keyword suggestion tool.
= 1.15.1
- Fix issue #184 – The position of typing dialog should be under the focused line.
- Fix issue #187 – Task List – Compatible with PHP 7.4
= 1.15.2
- Fix errors in WP CLI.
= 1.16.0
- Fix issue #209 – HTML unescaped in code blocks.
- Fix issue #210 – Inline MathJax is not displayed.
- Upgrade Mermaid JavaScript library from 8.0.0 to 8.9.0
- Upgrade KaTax JavaScript library from 0.11.1 to 0.12.0
- Upgrade Flowchart.js JavaScript library from 1.11.3 to 1.14.1
= 1.16.1
- Fix issue #253 – KaTax… by xxNull-lsk
- Fix issue #252 – Bulk action… by hmaragy
- Improve #252 Update composer.json to allow bedrock installs by jawngee
- Fix issue #230 – jsdeliver url by Bronya0
- Test up to WordPress 5.8.1
- Test up to PHP 8.0
= 1.16.2
- Test for compatibility with WordPress 6.2.2 and PHP 8.2.5 (No new updates for this version, just testing for compatibility)
- Fix coding style.
- Mermaid.js has been updated to 9.4.3
= 1.16.3
- Fix a security issue for ImagePaste module.
- Add jQuery dependency for the themes that don’t have jQuery loaded.