=== SyntaxHighlighter Evolved === Contributors: Viper007Bond, automattic, donncha Donate link: https://alex.blog/2019/03/13/in-memory-of-alex-donation-link-update/ Tags: code, source, sourcecode, php, syntax highlighting, syntax, highlight, highlighting, highlighter, WordPress.com Requires at least: 5.7 Tested up to: 6.4 Stable tag: 3.7.0 Easily post syntax-highlighted code to your site without having to modify the code at all. As seen on WordPress.com. == Description == *Now with support for the new block editor in WordPress 5.0!* SyntaxHighlighter Evolved allows you to easily post syntax-highlighted code to your site without losing its formatting or making any manual changes. It uses the [SyntaxHighlighter JavaScript package by Alex Gorbatchev](http://alexgorbatchev.com/wiki/SyntaxHighlighter). For a live demo, see [this plugin's homepage](https://alex.blog/wordpress-plugins/syntaxhighlighter/). For a list of supported languages (most widely used languages are supported), see the [WordPress.com support document](http://en.support.wordpress.com/code/posting-source-code/). Development of this plugin is [on GitHub](https://github.com/Automattic/syntaxhighlighter). Translation of the plugin into different languages is on the [translation page](https://translate.wordpress.org/projects/wp-plugins/syntaxhighlighter). *[As seen on WordPress.com.](http://en.blog.wordpress.com/2009/12/02/better-source-code-posting/)* == Frequently Asked Questions == = The code is just being displayed raw. It isn't being converted into a code box or anything. What's wrong? = Make sure your theme's `footer.php` file has `` somewhere inside of it, otherwise the plugin won't be able to do it's thing. = Highlighting doesn't work and my browser hangs, why? Try excluding this plugin's Javascript from any performance optimizations your site may be doing that involve minifying or concatenating JS. == Screenshots == 1. Example display of some PHP code. 2. An example use of the editor block. == ChangeLog == = Version 3.7.0 = - Update translations with translator comment to a single line. #245 - Fix nested shortcode bugs. #261 - PHP 8 Compat: declare class properties. #265 - Migrate project to wp-scripts and fix lodash deps. #269 = Version 3.6.2 = * New: Add syntax highlight for Swift. #232 = Version 3.6.1 = * New: Set code block language when pasting into editor. #215 * New: Add syntax highlight for Haskell. #210 * New: Display the list of available brushes. #221 * Fix: Line alignment for bootstrap themes. #222 * Fix: Add space around code. #223 * Fix: XML brush - use the last occurrence of the tag. #225 = Version 3.6.0 = * New: Add ```language shortcut. #180 * New: Add block alignment support. #179 * New: Add language selector to block toolbar. #172 * Fix: transform issue. #201 * Fix: toolbar code selection for latest Gutenberg versions #200 * Fix: Content attribute selector. #178 * Fix: Escaping for shortcodes and URLs. #177 * Fix: Escaping issues with HTML entities. #160 * Fix: MatLab brush key in brush map. #188 * Fix: Remove wrapper. #163 * Fix: escaping for non-admin authored posts. #187 * Tweak: Bump "tested up to" version. #183 * Tweak: Refactor block JS code. #171 * Tweak: Update plugin tags. #181 * Tweak: Use tab size from plugin settings in block editor. #174 = Version 3.5.5 = * Allow setting text to include br and code tags. #144 * Add Arduino Brush. #136 * Fix tags issue while alternating visual and text mode in the classic editor. #139 * Fix adding classname when using SyntaxHighlighter block. #138 = Version 3.5.4 = * Add missing shBrushYaml file. = Version 3.5.3 = * Add "edit mode on double click" option to settings, shortcode parameters and block editor. #126 * Add YAML highlighter. #129 * Update plugin dependencies to the latest version. #132 = Version 3.5.2 = * Update plugin dependencies to the latest version. = Version 3.5.1 = * Fix stored XSS by tightening up the autolinking code so it only does http/https text. #1 * Add more CSS keywords and values. #6 * Fork GH repository: https://github.com/Automattic/syntaxhighlighter/ = Version 3.5.0 = * Block: Add a bunch of display settings. * Block: Switch to server-side rendering so that the same code that renders the shortcode will render the block. = Version 3.4.2 = * Blocks: Support SyntaxHighlighter block being used as a reusable block. = Version 3.4.1 = * Bring back support for the Gutenberg plugin for the people that are still on older versions of WordPress (pre-5.0) and are using the new block editor via the Gutenberg plugin. = Version 3.4.0 = * Drop support for the Gutenberg plugin in favor of WordPress 5.0's native functionality (different function names). = Version 3.3.2 = * Gutenberg: If a language isn't selected in the block configuration, default to plain text. = Version 3.3.1 = * Make sure `wp-editor` script is loaded for Gutenberg. = Version 3.3.0 = * Gutenberg block thanks to @iandunn. * Add a few extra keywords to the JavaScript highlighter. Props @caitp. = Version 3.2.1 = * Fix shortcode issues that would occur during post editing if the code contained what looked like opening HTML tags such as `` tag. Props [NoMad1337](http://www.tacticalcode.de/). = Version 3.1.6 = * Kill off v2 copy-to-clipboard SWF file due to XSS security issue with the file. If you want to be able to copy/paste, use the better v3. * Switch from using a `` tag to a `