Jeff Starr пре 7 година
родитељ
комит
445d89b521
1 измењених фајлова са 19 додато и 17 уклоњено
  1. +19
    -17
      readme.txt

+ 19
- 17
readme.txt Прегледај датотеку

@@ -132,13 +132,13 @@ Once the settings are configured, you can enable syntax highlighting for any cod
* Wrap multi-line code with pre & code tags: <pre><code>...</code></pre> * Wrap multi-line code with pre & code tags: <pre><code>...</code></pre>
* Wrap single-line code with code tags: <code>...</code> * Wrap single-line code with code tags: <code>...</code>


Note: Prism.js highlights both multi-line and single-line code snippets. Highlight.js only supports multi-line code snippets.
__Note:__ Prism.js highlights both multi-line and single-line code snippets. Highlight.js only supports multi-line code snippets.


With the proper markup in place, you can indicate a specific language by adding a class of language-*** or lang-*** to the <code> tag (where *** is the language identifier). For example, to indicate PHP as the language for a single-line code snippet: With the proper markup in place, you can indicate a specific language by adding a class of language-*** or lang-*** to the <code> tag (where *** is the language identifier). For example, to indicate PHP as the language for a single-line code snippet:


<code class="language-php"><?php echo 'Hello world'; ?></code> <code class="language-php"><?php echo 'Hello world'; ?></code>


Likewise, to indicate HTML as the language for a multi-line code snippet (note: if you are reading this plugin's raw readme.txt file, [click here](https://wordpress.org/plugins/prismatic/installation/) to read the formatted text):
Likewise, to indicate HTML as the language for a multi-line code snippet:


<pre><code class="language-html"> <pre><code class="language-html">
<table> <table>
@@ -172,23 +172,25 @@ Just like Prism.js and Highlight.js, the Prismatic plugin follows HTML coding st


For example, the code snippets included in either of the following markup examples would be escaped: For example, the code snippets included in either of the following markup examples would be escaped:


This is a single-line example, &lt;code&gt;&lt;?php echo 'Hello world'; ?&gt;&lt;/code&gt;.
This is a single-line example:


This is a multi-line code example (note: if you are reading this plugin's raw readme.txt file, [click here](https://wordpress.org/plugins/prismatic/installation/) to read the formatted text):
<code class="language-php"><?php echo 'Hello world'; ?></code>.

This is a multi-line code example:
&lt;pre&gt;&lt;code&gt;<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;table&gt;<br>
&nbsp;&nbsp;&nbsp;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td>
<td>Dark</td>
<td>Sith</td>
</tr>
</table>
</code></pre>


So what exactly happens when the "Code Escaping" options are enabled? Here is a summary that applies to each section (post content, excerpts, and comments): So what exactly happens when the "Code Escaping" options are enabled? Here is a summary that applies to each section (post content, excerpts, and comments):




Loading…
Откажи
Сачувај