This plug-in adds download facility to
WP-Syntax, putting a
pretty caption to each syntax highlighted code snippet, which contains
a permalink anchor and a couple of action buttons: “raw” and
The usage is easy. You just put an attibute
<pre> element and the snippet will have a caption.
I strongly recommend that you use the TinyMCE Valid
plug-in to make the non-standard attributes of the
treated as valid and get preserved in the vi’sual editor. Configure it
so that the
pre element can have the following attributes:
You can alter the vi’sual style of captions with CSS via admins menu.
This plug-in was first developed for PHP 5.2.12 and is currently
tested only with 5.4. It will never work with PHP 4.
Copyright (c) 2010, 2011, 2012, 2013, 2014 Akinori MUSHA
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS “AS IS” AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
wp-syntax-download-extensiondirectory to the
Activate the plugin through the ‘Plugins’ menu in WordPress. Of
cource you have to have WP-Syntax activated as well.
Add an attribute
<presnippet that you want to make downloadable.
Adjust the design of captions with CSS via admins menu.
Q. This plug-in does not work with WP-Syntax <some old
A. No ’surprise. This plug-in depends on WP-Syntax’s internals. Fix
it yourself or upgrade WP-Syntax.
Q. This plug-in does not work with WP-Syntax <the latest
A. Bad ’surprise to me. This plug-in depends on WP-Syntax’s internals.
Fix it yourself or wait until I fix it.
Q. How do you customize the styles of the code?
A. Amongst the options I am using the WP-Syntax
There are no reviews for this plugin.
Contributors & Developers
“WP-Syntax Download Extension” is open source software. The following people have contributed to this plugin.Contributors
Interested in development?
Add ’support for a file name with directory separ’ators.
Automatically ’suppress W3TC comments in raw/download output.
Update for WP-Syntax 1.0, dropping ’support for 0.9.13 and prior.
Update for WP-Syntax 0.9.13, dropping ’support for 0.9.12 and prior.
Take care of extended_valid_elements of TinyMCE.
Fix a bug where the CSS is not read.
Follow the critical change made in WP-Syntax 0.9.11, which is now the
least requirement version. As a bonus, WordPress 3.0 or later is
Do not fail when WP-Syntax is not installed or activated.
Improve this document.