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

Lite Syntax Highlighting

描述

The Plugin makes it easy to add syntax highlighting of code in your blog. You can use shortcodes in posts and comments and also html tags everywhere.

It adds some buttons to editor, which generate special short code tags to turn on syntax highlighting: [slh lang=”php”] for example. And you can use html tags, example: <pre class=”slh__html”></pre>

The plugin supports highlighting:

  • PHP
  • HTML
  • CSS
  • JavaScript
  • C

Languages:

  • English
  • Русский

Styles:

  • Light
  • Dark

螢幕截圖

  • Example for PHP code
  • Settings page
  • Editor
  • Dark style

安裝

  1. Upload the plugin files to the “/wp-content/plugins/” directory or install the plugin through the WordPress plugins screen directly..
  2. Activate the plugin through the “Plugins” menu in WordPress.
  3. Use the Settings -> Syntax Highlighting screen to configure the plugin

常見問題

What code is highlighted?

PHP, HTML, CSS, JavaScript and C

How can I help?

There are public repository: https://github.com/z17/Lite-Syntax-Highlighting
Welcome!

How can I use it?

You can use special buttons in WordPress post editor, or use shortcodes like [slh lang=”php”] to create block of code.
Also you can just write html tags <pre class=”slh__php”> CODE </pre> where you want.

How can I ask something?

Open new topic in support section or you can write me email, admin@blweb.ru

評價

2016年9月3日 1 reply
It is so simple and as my site don't need a ton of feature I only post css and php little bit. This plugin just fit my need. Thank you so much.
閱讀全部2個評價

貢獻者及開發者

“Lite Syntax Highlighting” 是一個開源的軟體。以下的人對這個外掛作出了貢獻。

貢獻者

Lite Syntax Highlighting 外掛目前已有 2 個本地化語言版本。 感謝所有譯者為這個外掛做出的貢獻。

將 Lite Syntax Highlighting 外掛本地化為台灣繁體中文版。

對開發相關資訊感興趣?

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

修改日誌

0.5

  • add support short codes
  • short codes also work in comments

0.4

  • add basic highlight for C language
  • some refactor

0.3

  • add dark style

0.2

  • Add languages support

0.1

  • Initial release.