=== Code Snippets CPT === Plugin Name: Code Snippets CPT Plugin URI: http://dsgnwrks.pro/plugins/code-snippets-cpt Contributors: jtsternberg Donate link: http://j.ustin.co/rYL89n Author URI: http://dsgnwrks.pro Author: Jtsternberg Tags snippets, code, code snippets, syntax highlighting, shortcode Requires at least: 3.8.0 Tested up to: 4.7.3 Stable tag: 2.1.0 License: GPLv2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html A WordPress plugin for elegantly hosting, managing, and displaying code snippets. Own your own data! == Description == A WordPress plugin for elegantly hosting, managing, and displaying code snippets. Own your own data! Adds a custom post type for managing your code snippets with taxonomies for classifying the snippets. Embed snippets with syntax highlighting to posts or pages via a handy shortcode insert button that allows you to pick from the most recent snippets. Syntax highlighting provided by the [Prettify javascript library](https://github.com/google/code-prettify) and the [Ace Editor](https://ace.c9.io/). Features: * Host your own snippet library. * Button for easy-copying of snippet (disable with: `add_filter( 'dsgnwrks_snippet_do_click_to_copy', '__return_false' )`). * Button to enable full-screen snippet view (disable with: `add_filter( 'dsgnwrks_snippet_enable_full_screen_view', '__return_false' )`). * Two frontend render engines, prettify (with 2 themes) or Ace (with 32 themes). * WordPress editor shortcode button for embedding snippets in your content, and creating/editing those snippets on the fly. * Live (tinymce) previews of the snippets in your content editor. * Programming language picker (for syntax). * Snippet tags and categories. Feel free to [fork or contribute on Github](https://github.com/jtsternberg/Code-Snippets-CPT). == Installation == 1. Upload the entire `/code-snippets-cpt` directory to the `/wp-content/plugins/` directory. 2. Activate Code Snippets CPT through the 'Plugins' menu in WordPress. 3. Create a snippet. 4. Insert a snippet shortcode via the snippet tinymce button. == Screenshots == 1. Code Snippets admin listing 2. Editing code snippet 3. Code snippet shortcode in a post 4. Code snippet insert button/modal 5. Front-end snippet view, using Ace with the monokai theme 6. Full-screen snippet view 7. Snippet easy-copy window 8. Inline snippet editor == Changelog == = 2.1.0 = * Fix issue with double trailing slashes on `DWSNIPPET_URL` causing resources to no load under some circumstances. = 2.0.9 = * Fix issue with calling `wp.mce` when it doesn't exist (in instances where only quicktags are enqueued). = 2.0.8 = * Fix ACE frontend to honor the 'Display Line Numbers' setting. Fixes [#29](https://github.com/jtsternberg/Code-Snippets-CPT/issues/29). = 2.0.7 = * Fix "Uncaught Error: Call to undefined function post_categories_meta_box()" occurring when not on post-pages. Fixes [#28](https://github.com/jtsternberg/Code-Snippets-CPT/issues/28). = 2.0.6 = * Update snippet-copy URL so that it doesn't 404 when nonce is expired, and also `noindex,nofollow` the snippet-copy pages when the nonce has expired. = 2.0.5 = * Enable native copy functionality available in newer browsers. Props [ramiabraham](https://github.com/ramiabraham), [#27](https://github.com/jtsternberg/Code-Snippets-CPT/pull/27). * Clean up styles a bit for full-screen view. * Clean up Ace front-end view. = 2.0.4 = * Fix bug causing the shortcode button not to insert the snippet when in visual mode. = 2.0.3 = * The front-end script needs to load in the footer so that `wp_localize_script()` works as expected. * Better styling for the full-width view and the buttons in the full-width view = 2.0.2 = * Better Ace editor support for inline php snippets (i.e. no opening `