{"id":1736,"date":"2007-04-09T07:40:45","date_gmt":"2007-04-09T07:40:45","guid":{"rendered":"https:\/\/wordpress.org\/plugins-wp\/codecolorer\/"},"modified":"2026-03-14T01:31:44","modified_gmt":"2026-03-14T01:31:44","slug":"codecolorer","status":"publish","type":"plugin","link":"https:\/\/pcd.wordpress.org\/plugins\/codecolorer\/","author":64444,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_crdt_document":"","version":"0.11.0","stable_tag":"0.11.0","tested":"6.9.4","requires":"4.0","requires_php":"7.0","requires_plugins":null,"header_name":"CodeColorer","header_author":"Dmytro Shteflyuk","header_description":"","assets_banners_color":"cccac6","last_updated":"2026-03-14 01:31:44","external_support_url":"","external_repository_url":"","donate_link":"","header_plugin_uri":"https:\/\/kpumuk.info\/projects\/wordpress-plugins\/codecolorer\/","header_author_uri":"https:\/\/kpumuk.info\/","rating":4.9,"author_block_rating":0,"active_installs":1000,"downloads":125367,"num_ratings":11,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","faq","changelog"],"tags":{"0.10.0":{"tag":"0.10.0","author":"kpumuk","date":"2023-04-29 01:44:22"},"0.10.1":{"tag":"0.10.1","author":"kpumuk","date":"2023-05-29 00:58:07"},"0.10.2":{"tag":"0.10.2","author":"kpumuk","date":"2026-03-12 23:07:21"},"0.11.0":{"tag":"0.11.0","author":"kpumuk","date":"2026-03-14 01:31:44"},"0.5.1":{"tag":"0.5.1","author":"kpumuk","date":"2007-04-10 11:58:01"},"0.6.0":{"tag":"0.6.0","author":"kpumuk","date":"2007-05-12 18:01:32"},"0.7.0":{"tag":"0.7.0","author":"kpumuk","date":"2008-12-29 23:25:03"},"0.7.2":{"tag":"0.7.2","author":"kpumuk","date":"2008-12-30 16:13:07"},"0.7.3":{"tag":"0.7.3","author":"kpumuk","date":"2009-01-27 16:21:46"},"0.8.0":{"tag":"0.8.0","author":"kpumuk","date":"2009-07-13 12:37:21"},"0.8.1":{"tag":"0.8.1","author":"kpumuk","date":"2009-07-13 15:01:51"},"0.8.2":{"tag":"0.8.2","author":"kpumuk","date":"2009-07-14 02:44:44"},"0.8.3":{"tag":"0.8.3","author":"kpumuk","date":"2009-07-14 14:19:31"},"0.8.4":{"tag":"0.8.4","author":"kpumuk","date":"2009-07-14 16:08:32"},"0.8.5":{"tag":"0.8.5","author":"kpumuk","date":"2009-07-20 13:12:25"},"0.8.6":{"tag":"0.8.6","author":"kpumuk","date":"2009-07-22 08:13:59"},"0.8.7":{"tag":"0.8.7","author":"kpumuk","date":"2009-07-23 11:48:39"},"0.9.0":{"tag":"0.9.0","author":"kpumuk","date":"2009-07-30 12:57:04"},"0.9.1":{"tag":"0.9.1","author":"kpumuk","date":"2009-08-01 10:22:15"},"0.9.10":{"tag":"0.9.10","author":"kpumuk","date":"2017-07-29 14:28:07"},"0.9.11":{"tag":"0.9.11","author":"kpumuk","date":"2017-08-09 14:46:44"},"0.9.12":{"tag":"0.9.12","author":"kpumuk","date":"2017-10-12 23:47:49"},"0.9.13":{"tag":"0.9.13","author":"kpumuk","date":"2017-10-24 14:36:22"},"0.9.14":{"tag":"0.9.14","author":"kpumuk","date":"2017-10-25 07:20:19"},"0.9.15":{"tag":"0.9.15","author":"kpumuk","date":"2018-02-25 03:41:27"},"0.9.16":{"tag":"0.9.16","author":"kpumuk","date":"2018-07-23 11:19:55"},"0.9.2":{"tag":"0.9.2","author":"kpumuk","date":"2009-08-01 13:57:54"},"0.9.3":{"tag":"0.9.3","author":"kpumuk","date":"2009-08-24 11:29:30"},"0.9.4":{"tag":"0.9.4","author":"kpumuk","date":"2009-08-24 11:31:05"},"0.9.5":{"tag":"0.9.5","author":"kpumuk","date":"2009-08-27 20:37:46"},"0.9.6":{"tag":"0.9.6","author":"kpumuk","date":"2009-12-18 15:36:41"},"0.9.7":{"tag":"0.9.7","author":"kpumuk","date":"2009-12-19 11:52:30"},"0.9.8":{"tag":"0.9.8","author":"kpumuk","date":"2010-03-23 15:39:39"},"0.9.9":{"tag":"0.9.9","author":"kpumuk","date":"2011-04-28 20:43:44"}},"upgrade_notice":[],"ratings":{"1":0,"2":0,"3":0,"4":"1","5":"10"},"assets_icons":{"icon-128x128.png":{"filename":"icon-128x128.png","revision":1705164,"resolution":"128x128","location":"assets","locale":""},"icon-256x256.png":{"filename":"icon-256x256.png","revision":1705147,"resolution":"256x256","location":"assets","locale":""}},"assets_banners":{"banner-1544x500.png":{"filename":"banner-1544x500.png","revision":1705292,"resolution":"1544x500","location":"assets","locale":""},"banner-772x250.png":{"filename":"banner-772x250.png","revision":1705292,"resolution":"772x250","location":"assets","locale":""}},"assets_blueprints":{"blueprint.json":{"filename":"blueprint.json","revision":3484238,"resolution":false,"location":"assets","locale":"","contents":"{\"landingPage\":\"\\\/?p=1\",\"plugins\":[\"codecolorer\"],\"steps\":[{\"step\":\"setSiteOptions\",\"options\":{\"codecolorer_line_numbers\":\"true\",\"codecolorer_width\":\"\",\"codecolorer_disable_keyword_linking\":\"true\"}},{\"step\":\"runPHP\",\"code\":\"<?php\\nrequire '\\\/wordpress\\\/wp-load.php';\\n\\n$posts = get_posts(array(\\n    'numberposts' => -1,\\n    'post_type' => array('post', 'page'),\\n    'post_status' => 'any'\\n));\\n\\nforeach ($posts as $post) {\\n    wp_delete_post($post->ID, true);\\n}\"},{\"step\":\"importWxr\",\"file\":{\"resource\":\"url\",\"url\":\"https:\\\/\\\/raw.githubusercontent.com\\\/kpumuk\\\/codecolorer\\\/refs\\\/heads\\\/main\\\/.wordpress-org\\\/assets\\\/blueprints\\\/content\\\/codecolorer-plugin-demo.xml\"}},{\"step\":\"installPlugin\",\"pluginData\":{\"resource\":\"wordpress.org\\\/plugins\",\"slug\":\"codecolorer\"},\"options\":{\"activate\":true}}],\"preferredVersions\":{\"php\":\"8.3\",\"wp\":\"latest\"},\"login\":true}"}},"all_blocks":[],"tagged_versions":["0.10.0","0.10.1","0.10.2","0.11.0","0.5.1","0.6.0","0.7.0","0.7.2","0.7.3","0.8.0","0.8.1","0.8.2","0.8.3","0.8.4","0.8.5","0.8.6","0.8.7","0.9.0","0.9.1","0.9.10","0.9.11","0.9.12","0.9.13","0.9.14","0.9.15","0.9.16","0.9.2","0.9.3","0.9.4","0.9.5","0.9.6","0.9.7","0.9.8","0.9.9"],"block_files":[],"assets_screenshots":{"screenshot-1.png":{"filename":"screenshot-1.png","revision":1705164,"resolution":"1","location":"assets","locale":""},"screenshot-2.png":{"filename":"screenshot-2.png","revision":1705164,"resolution":"2","location":"assets","locale":""},"screenshot-3.png":{"filename":"screenshot-3.png","revision":1705164,"resolution":"3","location":"assets","locale":""},"screenshot-4.png":{"filename":"screenshot-4.png","revision":1705164,"resolution":"4","location":"assets","locale":""}},"screenshots":{"1":"Ruby syntax highlighting without scrollbars (Vibrant theme).","2":"Ruby syntax highlighting with scrollbars (Twitlight theme).","3":"Inline code syntax highlighting.","4":"Settings page."},"jetpack_post_was_ever_published":false},"plugin_section":[],"plugin_tags":[1214,107,5284,9309,2207],"plugin_category":[44],"plugin_contributors":[80686],"plugin_business_model":[],"class_list":["post-1736","plugin","type-plugin","status-publish","hentry","plugin_tags-code","plugin_tags-comments","plugin_tags-highlighting","plugin_tags-snippet","plugin_tags-syntax","plugin_category-discussion-and-community","plugin_contributors-kpumuk","plugin_committers-kpumuk"],"banners":{"banner":"https:\/\/ps.w.org\/codecolorer\/assets\/banner-772x250.png?rev=1705292","banner_2x":"https:\/\/ps.w.org\/codecolorer\/assets\/banner-1544x500.png?rev=1705292","banner_rtl":false,"banner_2x_rtl":false},"icons":{"svg":false,"icon":"https:\/\/ps.w.org\/codecolorer\/assets\/icon-128x128.png?rev=1705164","icon_2x":"https:\/\/ps.w.org\/codecolorer\/assets\/icon-256x256.png?rev=1705147","generated":false},"screenshots":[{"src":"https:\/\/ps.w.org\/codecolorer\/assets\/screenshot-1.png?rev=1705164","caption":"Ruby syntax highlighting without scrollbars (Vibrant theme)."},{"src":"https:\/\/ps.w.org\/codecolorer\/assets\/screenshot-2.png?rev=1705164","caption":"Ruby syntax highlighting with scrollbars (Twitlight theme)."},{"src":"https:\/\/ps.w.org\/codecolorer\/assets\/screenshot-3.png?rev=1705164","caption":"Inline code syntax highlighting."},{"src":"https:\/\/ps.w.org\/codecolorer\/assets\/screenshot-4.png?rev=1705164","caption":"Settings page."}],"raw_content":"<!--section=description-->\n<p>CodeColorer lets you insert syntax-highlighted code snippets into posts, comments, and feeds.<\/p>\n\n<p>CodeColorer currently bundles GeSHi 1.0.9.0 from the upstream 1.0.x line, with a small set of project-local maintenance patches for current PHP and WordPress compatibility.<\/p>\n\n<p>Plugin based on GeSHi library, which supports most languages. CodeColorer has various nice features:<\/p>\n\n<ul>\n<li>syntax highlighting in RSS feeds<\/li>\n<li>syntax highlighting of a single line of code (inline)<\/li>\n<li>syntax highlighting of code in comments<\/li>\n<li>line numbers<\/li>\n<li>automatic links to the documentation inserting<\/li>\n<li>code block intelligent scroll detection (short code would have a short block, for a long one the block height would be fixed and a scrollbar would appear)<\/li>\n<li>predefined color themes (Slush &amp; Poppies, Blackboard, Dawn, Mac Classic, Twitlight, Vibrant Ink, Railscasts, Solarized Light, Solarized Dark)<\/li>\n<li>syntax colors customization in CSS file<\/li>\n<li>code protect from mangling by Wordpress (for example, quotes, double-dashes, and others would look just right as you entered)<\/li>\n<\/ul>\n\n<h4>Support<\/h4>\n\n<p>If you have any suggestions, found a bug, wanted to contribute a translation to your language, or just wanted to say \"thank you\", feel free to email me <a href=\"mailto:kpumuk@kpumuk.info\">kpumuk@kpumuk.info<\/a>. I will try my best to answer you.<\/p>\n\n<p>If you want to contribute your code, see the <em>Development<\/em> section under the <em>Other Notes<\/em> tab.<\/p>\n\n<h3>Supported languages<\/h3>\n\n<p>Here is the list of languages supported by CodeColorer: 4cs, 6502acme, 6502kickass, 6502tasm, 68000devpac, abap, actionscript, actionscript3, ada, aimms, algol68, apache, applescript, apt_sources, arm, asm, asp, asymptote, autoconf, autohotkey, autoit, avisynth, awk, bascomavr, bash, basic4gl, batch, bf, biblatex, bibtex, blitzbasic, bnf, boo, c, c_loadrunner, c_mac, c_winapi, caddcl, cadlisp, ceylon, cfdg, cfm, chaiscript, chapel, cil, clojure, cmake, cobol, coffeescript, cpp-qt, cpp-winapi, cpp, csharp, css, cuesheet, d, dart, dcl, dcpu16, dcs, delphi, diff, div, dos, dot, e, ecmascript, eiffel, email, epc, erlang, euphoria, ezt, f1, falcon, fo, fortran, freebasic, freeswitch, fsharp, gambas, gdb, genero, genie, gettext, glsl, gml, gnuplot, go, groovy, gwbasic, haskell, haxe, hicest, hq9plus, html4strict, icon, idl, ini, inno, intercal, io, ispfpanel, j, java, java5, javascript, jcl, jquery, julia, kixtart, klonec, klonecpp, kotlin, latex, lb, ldif, lisp, llvm, locobasic, logtalk, lolcode, lotusformulas, lotusscript, lscript, lsl2, lua, m68k, magiksf, make, mapbasic, mathematica, matlab, mercury, metapost, mirc, mk-61, mmix, modula2, modula3, mpasm, mxml, mysql, nagios, netrexx, newlisp, nginx, nimrod, nsis, oberon2, objc, objeck, ocaml-brief, ocaml, octave, oobas, oorexx, oracle11, oracle8, oxygene, oz, parasail, parigp, pascal, pcre, per, perl, perl6, pf, phix, php-brief, php, pic16, pike, pixelbender, pli, plsql, postgresql, postscript, povray, powerbuilder, powershell, proftpd, progress, prolog, properties, providex, purebasic, pycon, pys60, python, q, qbasic, qml, racket, rails, rbs, rebol, reg, rexx, robots, rpmspec, rsplus, ruby, rust, sas, sass, scala, scheme, scilab, scl, sdlbasic, smalltalk, smarty, spark, sparql, sql, standardml, stonescript, swift, systemverilog, tcl, tclegg, teraterm, texgraph, text, thinbasic, tsql, twig, typoscript, unicon, upc, urbi, uscript, vala, vb, vbnet, vbscript, vedit, verilog, vhdl, vim, visualfoxpro, visualprolog, whitespace, whois, winbatch, xbasic, xml, xojo, xorg_conf, xpp, xyscript, yaml, z80, zxbasic.<\/p>\n\n<h3>Development<\/h3>\n\n<p>Sources of this plugin are available both in SVN and Git:<\/p>\n\n<ul>\n<li><a href=\"https:\/\/plugins.svn.wordpress.org\/codecolorer\/\">WordPress SVN repository<\/a><\/li>\n<li><a href=\"https:\/\/github.com\/kpumuk\/codecolorer\/\">GitHub<\/a><\/li>\n<\/ul>\n\n<p>The GitHub repository includes local contributor tooling based on <code>mise<\/code>, Composer, <code>pnpm<\/code>, and <code>wp-env<\/code>. A typical setup is:<\/p>\n\n<ol>\n<li><code>mise install<\/code><\/li>\n<li><code>mise run bootstrap<\/code><\/li>\n<li><code>mise run test<\/code><\/li>\n<li><code>mise run wp-start<\/code><\/li>\n<\/ol>\n\n<p>Feel free to check them out, make your changes and send me patches or pull requests. Promise, I will apply every patch (of course, if they add a value to the product). Email for patches, suggestions, or bug reports: <a href=\"mailto:kpumuk@kpumuk.info\">kpumuk@kpumuk.info<\/a>.<\/p>\n\n<p>If you're interested in translating CodeColorer to your language, please check out the <a href=\"https:\/\/translate.wordpress.org\/projects\/wp-plugins\/codecolorer\">translation page<\/a> for the plugin.<\/p>\n\n<h3>Customization<\/h3>\n\n<p>Syntax coloring is highly customizable: you could change the  color scheme for all languages or a specific language. You could find CodeColorer CSS in <strong>wp-content\/plugins\/codecolorer\/codecolorer.css<\/strong> file. To change colors for all languages edit lines below <em>Color scheme<\/em> section.<\/p>\n\n<p>There is a simple mapping between TextMate color themes and CodeColorer ones:<\/p>\n\n<pre><code>\/* \"Slush &amp; Poppies\" color scheme (default) *\/\n.codecolorer-container, .codecolorer { color: #000000; background-color: #F1F1F1; }\n\/* Comment *\/\n.codecolorer .co0, .codecolorer .co1, .codecolorer .co2, .codecolorer .co3, .codecolorer .co4, .codecolorer .coMULTI { color: #406040; font-style: italic; }\n\/* Constant *\/\n.codecolorer .nu0, .codecolorer .re3 { color: #0080A0; }\n\/* String *\/\n.codecolorer .st0, .codecolorer .st_h, .codecolorer .es0, .codecolorer .es1 { color: #C03030; }\n\/* Entity *\/\n.codecolorer .me1, .codecolorer .me2 { color: #0080FF; }\n\/* Keyword *\/\n.codecolorer .kw1, .codecolorer .kw2, .codecolorer .sy1 { color: #2060A0; }\n\/* Storage *\/\n.codecolorer .kw3, .codecolorer .kw4, .codecolorer .kw5, .codecolorer .re2 { color: #008080; }\n\/* Variable *\/\n.codecolorer .re0, .codecolorer .re1 { color: #A08000; }\n\/* Global color *\/\n.codecolorer .br0, .codecolorer .sy0 { color: #000000; }\n<\/code><\/pre>\n\n<p>Check the <strong>codecolorer.css<\/strong> file to get more examples.<\/p>\n\n<!--section=installation-->\n<ol>\n<li>Download and unpack plugin files to <strong>wp-content\/plugins\/codecolorer<\/strong> directory.<\/li>\n<li>Enable <strong>CodeColorer<\/strong> plugin on your <em>Plugins<\/em> page in <em>Site Admin<\/em>.<\/li>\n<li>Go to the <em>Settings &gt; CodeColorer<\/em> page in <em>Site Admin<\/em> and change the plugin options as you wish.<\/li>\n<li>Use <code>[cc lang=\"lang\"]code[\/cc]<\/code> or <code>&lt;code lang=\"lang\"&gt;code&lt;\/code&gt;<\/code> syntax to insert a code snippet into the post (you can skip <code>lang=\"lang\"<\/code> if you want a plain CodeColorer block without syntax highlighting). You can also use <code>[cci lang=\"lang\"]code[\/cci]<\/code> to format inline code (see the \"inline\" option description).<\/li>\n<li>Have fun!<\/li>\n<\/ol>\n\n<h4>Syntax<\/h4>\n\n<p>To insert a code snippet into your post (or comment) you can use <code>[cc lang=\"lang\"]code[\/cc]<\/code> or <code>&lt;code lang=\"lang\"&gt;code&lt;\/code&gt;<\/code> syntax. Starting from version 0.6.0 you can specify additional CodeColorer options inside the <code>[cc]<\/code> tag:<\/p>\n\n<pre><code>[cc lang=\"php\" tab_size=\"2\" lines=\"40\"]\n\/\/ some code\n[\/cc]\n<\/code><\/pre>\n\n<p>Note: You should always use double quotes or single quotes around the parameter value. Boolean values could be passed using string <em>true<\/em> or <em>false<\/em>, <em>on<\/em> or <em>off<\/em>, number <em>1<\/em> or <em>0<\/em>.<\/p>\n\n<h4>Shortcodes<\/h4>\n\n<p>Starting from CodeColorer 0.8.6 you can use shortcodes to insert code snippets. The general form looks like <code>[ccM_LANG]<\/code>, where <strong>LANG<\/strong> is your programming language, and <strong>M<\/strong> is one or more of the following modes:<\/p>\n\n<ul>\n<li><strong>i<\/strong> \u2013 <em>inline<\/em><\/li>\n<li><strong>e<\/strong> \u2013 <em>escaped<\/em><\/li>\n<li><strong>s<\/strong> \u2013 <em>strict<\/em><\/li>\n<li><strong>n<\/strong> \u2013 <em>line_numbers<\/em><\/li>\n<li><strong>b<\/strong> \u2013 <em>no_border<\/em><\/li>\n<li><strong>w<\/strong> \u2013 <em>no_wrap<\/em><\/li>\n<li><strong>l<\/strong> \u2013 <em>no_links<\/em><\/li>\n<\/ul>\n\n<p>Small letter means <strong>enabled<\/strong>, capital \u2013 <strong>disabled<\/strong>. Examples:<\/p>\n\n<p><em>PHP code with links enabled and line numbers disabled:<\/em><\/p>\n\n<pre><code>[cclN_php]\necho \"hello\"\n[\/cclN_php]\n<\/code><\/pre>\n\n<p><em>Already escaped HTML code:<\/em><\/p>\n\n<pre><code>[ccie_html]&amp;lt;html&amp;gt;[\/ccie_html]\n<\/code><\/pre>\n\n<p><em>Ruby code without wrapping having tab size equal to 4:<\/em><\/p>\n\n<pre><code>[ccW_ruby tab_size=\"4\"]\nattr_accessor :title\n[\/ccW_ruby]\n<\/code><\/pre>\n\n<p>More examples could be found on the <a href=\"https:\/\/kpumuk.info\/projects\/wordpress-plugins\/codecolorer\/examples\">CodeColorer Examples<\/a> page. You can find modes explained below.<\/p>\n\n<h4>Possible parameters<\/h4>\n\n<ul>\n<li><strong>lang<\/strong> (<em>string<\/em>) \u2013 source language.<\/li>\n<li><strong>tab_size<\/strong> (<em>integer<\/em>) \u2013 how many spaces would represent TAB symbol.<\/li>\n<li><strong>lines<\/strong> (<em>integer<\/em>) \u2013 how many lines would be block height without scroll; could be set to <em>-1<\/em> to remove vertical scrollbar.<\/li>\n<li><strong>width<\/strong> (<em>integer<\/em> or <em>string<\/em>) \u2013 block width.<\/li>\n<li><strong>height<\/strong> (<em>integer<\/em> or <em>string<\/em>) \u2013 height in pixels; used when the number of lines is greater than the \"lines\" value.<\/li>\n<li><strong>rss_width<\/strong> (<em>integer<\/em> or <em>string<\/em>) \u2013 block width in RSS feeds.<\/li>\n<li><strong>theme<\/strong> (<em>string<\/em>) \u2013 color theme (default, blackboard, dawn, mac-classic, twitlight, vibrant, geshi, railscasts, solarized-light, solarized-dark).<\/li>\n<li><strong>first_line<\/strong> (<em>integer<\/em>) \u2013 a number of the first line in the block.<\/li>\n<li><strong>highlight<\/strong> (<em>string<\/em>) \u2014 a comma-separated list of line numbers or ranges of line numbers to highlight (e.g. <code>1,5,8-11<\/code>).<\/li>\n<li><strong>escaped<\/strong> (<em>boolean<\/em>) \u2013 when <em>true<\/em> special HTML sequences like <code>&amp;lt;<\/code> or <code>&amp;#91;<\/code> will be treated as encoded (in this example as <code>&lt;<\/code> and <code>[<\/code> respectively.)<\/li>\n<li><strong>line_numbers<\/strong> (<em>boolean<\/em>) \u2013 when <em>true<\/em> line numbers will be added.<\/li>\n<li><strong>no_links<\/strong> (<em>boolean<\/em>) \u2013 when <em>false<\/em> keywords will be represented as links to manual.<\/li>\n<li><strong>inline<\/strong> (<em>boolean<\/em>) \u2013 when <em>true<\/em> forces code block to render inside ```. Used to paste a single line of code into the regular text.<\/li>\n<li><strong>strict<\/strong> (<em>boolean<\/em>) \u2013 when <em>true<\/em> <a href=\"http:\/\/qbnz.com\/highlighter\/geshi-doc.html#using-strict-mode\">strict mode<\/a> will be enabled. By default CodeColorer tries to guess whether strict mode is needed, so this option allows to force it on or off when automatic suggestion is wrong.<\/li>\n<li><strong>nowrap<\/strong> (<em>boolean<\/em>) \u2013 when <em>false<\/em> no horizontal scrollbar will be shown; instead code will be wrapped in the end of code box.<\/li>\n<li><strong>noborder<\/strong> (<em>boolean<\/em>) \u2013 when <em>true<\/em> no border will be shown around the code block.<\/li>\n<li><strong>no_cc<\/strong> (<em>boolean<\/em>) \u2013 when <em>true<\/em> the syntax in code block will not be highlighted, code will be rendered inside `<code>`` tag.<\/code><\/li>\n<li><strong>class<\/strong> (<em>string<\/em>) \u2013 additional CSS classes to add to the wrapper HTML element.<\/li>\n<li><strong>file<\/strong> (<em>string<\/em>) \u2014 when specified, code will be loaded from external file. Should be a relative to uploads folder path, only files from uploads are allowed to be embedded.<\/li>\n<\/ul>\n\n<p>You can use special tag <code>[cci]<\/code> instead of <code>[cc]<\/code> to force inline mode:<\/p>\n\n<pre><code>[cci lang=\"php\"]some code[\/cci]\n<\/code><\/pre>\n\n<p>Most of these parameters could be configured via the CodeColorer options page.<\/p>\n\n<p>To insert an example of CodeColorer shortcodes you can use something like this:<\/p>\n\n<pre><code>[cce_bash]\n&amp;amp;#91;cc lang=\"html\"]\n&lt;title&gt;CodeColorer short code colorized&lt;\/title&gt;\n&amp;amp;#91;\/cc]\n[\/cce_bash]\n<\/code><\/pre>\n\n<!--section=faq-->\n<dl>\n<dt id=\"how%20can%20i%20customize%20codecolorer%20css%20rules%3F\"><h3>How can I customize CodeColorer CSS rules?<\/h3><\/dt>\n<dd><p>Go to the <em>Settings &gt; CodeColorer<\/em> page in <em>Site Admin<\/em> and change the \"Custom CSS Styles\" option.<\/p><\/dd>\n<dt id=\"i%20see%20%26amp%3Blt%3B%20instead%20of%20%26lt%3B%20%28or%20other%20html%20entities%20like%20%26gt%3B%2C%20%26amp%3B%2C%20%26quot%3B%29%20in%20my%20code.\"><h3>I see &amp;lt; instead of &lt; (or other HTML entities like &gt;, &amp;, &quot;) in my code.<\/h3><\/dt>\n<dd><p>You should use <code>[cc escaped=\"true\"]<\/code> or <code>[cce]<\/code> in the visual editor when inserting code into the post.<\/p><\/dd>\n<dt id=\"does%20it%20highlight%20my%20code%20on%20the%20server%20or%20client%20side%3F\"><h3>Does it highlight my code on the server or client side?<\/h3><\/dt>\n<dd><p>CodeColorer performs code highlighting on the server; you could see HTML of the highlighted code in the page source.<\/p><\/dd>\n<dt id=\"does%20it%20produce%20valid%20xhtml%20source%3F\"><h3>Does it produce valid XHTML source?<\/h3><\/dt>\n<dd><p>Yes, resulting XHTML is completely valid.<\/p><\/dd>\n<dt id=\"could%20my%20visitors%20insert%20code%20snippets%20in%20comments%3F\"><h3>Could my visitors insert code snippets in comments?<\/h3><\/dt>\n<dd><p>Yes, CodeColorer supports code highlighting in comments using the same syntax, as you use in your blog posts.<\/p><\/dd>\n<dt id=\"how%20can%20i%20disable%20syntax%20highlighting%20for%20a%20particular%20%60%3Ccode%3E%60%20block%3F\"><h3>How can I disable syntax highlighting for a particular `<code>` block?<\/code><\/h3><\/dt>\n<dd><p>Use <code>&lt;code no_cc=\"true\"&gt;<\/code> option for your code block.<\/p><\/dd>\n<dt id=\"i%20have%20updated%20the%20plugin%20to%20the%20newest%20version%20and%20now%20i%20keep%20getting%20following%20warnings%3A\"><h3>I have updated the plugin to the newest version and now I keep getting following warnings:<\/h3><\/dt>\n<dd><p>Warning: array_keys() [function.array-keys]: The first argument should be an array in \/home\/wordpress\/wp-content\/plugins\/codecolorer\/lib\/geshi.php on line 3599<\/p>\n\n<p>Remove all files from the <strong>wp-content\/plugins\/codecolorer<\/strong> folder and unpack an archive with plugin again (thanks to <a href=\"http:\/\/blog.t-l-k.com\/\">Anatoliy 'TLK' Kolesnick<\/a>).<\/p><\/dd>\n<dt id=\"how%20do%20i%20insert%20code%20from%20an%20external%20file%3F\"><h3>How do I insert code from an external file?<\/h3><\/dt>\n<dd><p>You can upload this file with the WordPress uploader or put it somewhere in the uploads folder, and then specify the relative path with the <code>file=\"relative\/path\/to\/file\"<\/code> attribute:<\/p>\n\n<pre><code>[cc_ruby file=\"test_project\/main.rb\"][\/cc_ruby]\n<\/code><\/pre>\n\n<p>This snippet will insert code from the UPLOADS_DIR\/test_project\/main.rb file.<\/p><\/dd>\n<dt id=\"google%20website%20translator%20breaks%20my%20code%20blocks\"><h3>Google Website Translator breaks my code blocks<\/h3><\/dt>\n<dd><p>The solution is to add <code>notranslate<\/code> class to the list of \"Custom CSS Classes\" on the admin plugin settings page.<\/p><\/dd>\n<dt id=\"is%20this%20plugin%20gdpr%20compliant%3F\"><h3>Is this plugin GDPR compliant?<\/h3><\/dt>\n<dd><p>Yes. We do not store or process any user information.<\/p><\/dd>\n\n<\/dl>\n\n<!--section=changelog-->\n<h4>0.11.0<\/h4>\n\n<ul>\n<li>Fixed comment protection for suffixed shortcodes such as <code>[cc_php]<\/code> and <code>[cci_php]<\/code>.<\/li>\n<li>Modernized admin asset loading and hardening around settings sanitization, nonce-protected dismissals, and direct-access guards.<\/li>\n<li>Improved documentation and release metadata, including clearer usage docs and safer WordPress.org asset publishing.<\/li>\n<\/ul>\n\n<h4>0.10.2<\/h4>\n\n<ul>\n<li>Fixed stored XSS in shortcode attributes, including comment-rendered shortcodes.<\/li>\n<li>Improved compatibility coverage across supported PHP and WordPress versions with real WordPress integration tests.<\/li>\n<li>Modernized local development, CI, and release tooling for more reliable maintenance.<\/li>\n<\/ul>\n\n<h4>0.10.1 (May 28, 2023)<\/h4>\n\n<ul>\n<li>Addressed a script injection in custom CSS classes and custom CSS block.<\/li>\n<\/ul>\n\n<h4>0.10.0 (April 28, 2023)<\/h4>\n\n<ul>\n<li>Addressed compatibility issues with PHP 8.0+ and tested with the latest WordPress version.<\/li>\n<\/ul>\n\n<h4>0.9.16 (July 23, 2018)<\/h4>\n\n<ul>\n<li>Fixed a bug when iOS would adjust the text size for line numbers and code differently, leading to non-consistent line numeration.<\/li>\n<li>Added scrollbars on Webkit (especially important for iOS).<\/li>\n<li>CodeColorer block width can be number, percent, or em.<\/li>\n<li>Added integration with Simple Download Monitor.<\/li>\n<\/ul>\n\n<h4>0.9.15 (February 24, 2017)<\/h4>\n\n<ul>\n<li>IMPORTANT: Fixed a bug with CodeColorer breaking admin pages without editor.<\/li>\n<\/ul>\n\n<h4>0.9.14 (October 25, 2017)<\/h4>\n\n<ul>\n<li>IMPORTANT: Another line numbers column width issue for numbers bigger than 1000.<\/li>\n<\/ul>\n\n<h4>0.9.13 (October 24, 2017)<\/h4>\n\n<ul>\n<li>IMPORTANT: Fixed line numbers column width issue, introduces in the previous version.<\/li>\n<li>Fixed line numbers column position on RTL pages.<\/li>\n<\/ul>\n\n<h4>0.9.12 (October 12, 2017)<\/h4>\n\n<ul>\n<li>Fixed XML syntax highlighting colors.<\/li>\n<li>Fixed line highlighting color for dark themes.<\/li>\n<li>Added support for TablePress plugin.<\/li>\n<li>Line highlighting affects the whole block width, not only the code text.<\/li>\n<\/ul>\n\n<h4>0.9.11 (August 8, 2017)<\/h4>\n\n<ul>\n<li>Fixed an issue with TinyMCE when CodeColorer options were removed in the editor (thanks to <a href=\"https:\/\/github.com\/TheBox193\">Jonathan Stassen<\/a> for the suggestion).<\/li>\n<li>New art for the WordPress plugins page.<\/li>\n<li>Moved translations to https:\/\/translate.wordpress.org\/projects\/wp-plugins\/codecolorer. WordPress should automatically download language packs now.<\/li>\n<li>Lots of code style issues, should resolve all warnings in PHP logs.<\/li>\n<\/ul>\n\n<h4>0.9.10 (July 28, 2017)<\/h4>\n\n<ul>\n<li>Fixed a bug with large code blocks margins.<\/li>\n<li>Added Portuguese translation (thanks to <a href=\"http:\/\/lfscoutinho.net\/\">Luis Coutinho<\/a>).<\/li>\n<li>Added Indonesian translation (thanks to <a href=\"http:\/\/www.openscriptsolution.com\/\">Masino Sinaga<\/a>).<\/li>\n<li>Fixed PHP 7 compatibility issues (thanks to <a href=\"https:\/\/github.com\/kamermans\">Steve Kamerman<\/a> and <a href=\"https:\/\/github.com\/robfelty\">Robert Felty<\/a>).<\/li>\n<li>Fixed WordPress 4+ compatibility (editor button, settings page layout).<\/li>\n<li>Added \"Solarized Light\" and \"Solarized Dark\" themes (thanks to <a href=\"https:\/\/github.com\/mattkirman\">Matt Kirman<\/a>).<\/li>\n<\/ul>\n\n<p>You can find complete changelog on the <a href=\"https:\/\/kpumuk.info\/projects\/wordpress-plugins\/codecolorer\/history\/\">CodeColorer history<\/a> page.<\/p>","raw_excerpt":"Syntax highlighting for code snippets in posts, comments, and RSS, with inline code, themes, and line numbers.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/1736","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=1736"}],"author":[{"embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/kpumuk"}],"wp:attachment":[{"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=1736"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=1736"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=1736"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=1736"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=1736"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=1736"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}