=== CSS & JavaScript Toolbox === Contributors: wipeoutmedia Author URL: http://css-javascript-toolbox.com Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=EWDWF75JHT9Q6 Tags: Post, posts, admin, sidebar, page, pages, image, plug, plugin, customise, style, scripts, hack, Wordpress, HTML, CSS, JavaScript, HTML5, jQuery, PHP, code, script, scripts, manage, management, display, output, header, footer, apply, requests, match, hook, execute, run License: GPLv2 or later License URI: http://www.gnu.org/licenses/gpl-2.0.html Requires at least: 3.6 Tested up to: 3.7.1 Stable tag: 6.1.2 Easily add custom CSS, JavaScript, HTML and PHP code to unique CJT code blocks and assign them wherever you want. == Description == CSS & JavaScript Toolbox is a code management plugin that gives you the tools to easily and safely modify or extend the functionality and appearance of your WordPress-powered website. You do this by adding custom code directly into unique code blocks and assign them to pages, posts, custom posts, categories, URLs, expressions, and loads more! [youtube http://www.youtube.com/watch?v=Br4tVp6QFwA] = Upgrade to CJT Pro = You will get more power and flexibility, better security, and a lot more features, tools and options in CJT Pro. Features in Pro include: a code auto completion system (for CSS, JavaScript, PHP, and HTML), code block metabox support for Pages/Posts, heaps of editor tools, external script support, a powerful code template manager, script package installer, and the list goes on. [Click here to see all the benefits of CJT Pro](http://css-javascript-toolbox.com/) = Who is this plugin for? = This plugin is primarily intended for WordPress website developers and designers. But that is not to say that others would not be able to get use out of it. CJT can be used for a lot of things from teachers, students learning to code, to mum and dad bloggers wanting to add Google Analytics or other scripts to their website. = Have you ever thought? = - Wouldn't it be great to have an easy way to plug your code into a Wordpress installation without having to know how to create a Wordpress plugin OR having to modify files through FTP, etc? - How nice it would be if you could simply add code that works with WordPress internal code without hacking away at core files? - How about a nice simple way to change the appearance of a page or post in your Wordpress website? - What about a means to organise your scripts and blocks of code in a simple web interface? = How can CJT help you? = - The CJT plugin allows you to contribute to your Wordpress installation code via a simple web interface. You can modify and extend the functionality and appearance of your website by writing code directly into CJT code blocks. - Each code block represents a script (or block of code) that can apply/execute/output to a specific location (e.g. pages, posts, categories, etc) as defined in the Assignment Panel. - With CJT code blocks, you can add various types of code like CSS, JavaScript, HTML and PHP. You can mix them into a single block or organise them into multiple separate blocks - the choice is yours. - The Auxiliary tab provides more 'assignment' options. Things like WordPress common requests such as: 404 Error, Tag, Archive, Entire website, Front-end, Dashboard Backend, and a number of others. - You can create multiple code blocks, assign them to the same requests or different requests. - Manage all of your code blocks through a single webpage using Ajax requests. No need to refresh your pages for any operation you need to make. - Changing the blocks order (via block dragging) allows you to specify what code block is used first. This way later blocks are overridden by higher-order code blocks. - By Deactivating code blocks, you can disable a code block from running. Using this feature is handy to test the behaviour you expected your block to make without changing a blocks properties (i.e. code, assigned requests). - All code blocks can have a unique name, which is ideal for organising and remembering the purpose of your block. - Output location is the location/point/hook for the block code to run. CJT now only supports two hook points - Header and Footer, which outputs code block in the page header - exactly before the closing HTML 'head' tag OR in the page footer - just before the end of the 'body' tag. - Integrating with [ACE Editor](http://ace.ajax.org/)! CJT proudly and perfectly integrates the ACE Editor and it is a dream to use while writing code for its smooth response, high performance and syntax highlighting. - We have included a number of tools for batch processing like: 'Delete All Empty Blocks', 'Delete All', 'Activate All', 'Deactivate All', 'Revert State'. - Individual code block Revisions can be saved. Also, you can entirely save all of your code blocks with the Backups feature. = Would like to know more? = If you would like to learn more, please click to [download the CJT User Manual](http://css-javascript-toolbox.com/cjt-free-user-manual-free-download/). = Scripts, scripts, glorious scripts! = If you would like to learn how to use our plugin with some script examples, please visit our [Scripts page](http://css-javascript-toolbox.com/category/scripts). If you are a script author and would like to get more exposure for your scripts, please submit your scripts to us. Click [Submit a Script](http://css-javascript-toolbox.com/submit-a-script) to find out more. = Follow the Developments = If you like to know more about the development state, issues and to track future versions code please follow us on [GitHub Plugin repository](https://github.com/css-javascript-toolbox/css-javascript-toolbox-plugin). = Thank You = We would like to take this opportunity to thank you for installing our WordPress plugin. We will continue to develop it further, making it bigger and better with awesome updates in the near future. If you like this plugin and not only find it useful, but appreciate the huge amount of work that has gone into creating it, you can certainly support us in a number of ways, including: - Providing a [feedback review and rating](http://wordpress.org/support/view/plugin-reviews/css-javascript-toolbox) on WordPress.org - Visiting our [CJT website](http://css-javascript-toolbox.com) and letting us know your thoughts on using the plugin, notifying us of any bugs and issues, and providing us with feature requests. - Liking [CJToolbox on Facebook](https://www.facebook.com/CJToolbox) - Following [CJToolbox on Twitter](https://twitter.com/CJToolbox) - Subscribing to [CJToolbox on Youtube](http://www.youtube.com/user/cjtoolbox) Thank you very much for your support and we hope you enjoy using it as much as we enjoy developing it. Regards, Team CJT == Installation == 1. If you're upgrading from older versions its highly recommended to backup your database before upgrading. 2. Upload the 'css-js-toolbox' folder to the '/wp-content/plugins/' directory 3. Activate the plugin through the 'Plugins' menu in WordPress 4. Click 'CSS & JavaScript Toolbox' link in the main navigation (left side of your Dashboard). == Frequently Asked Questions == = Why was the CJT plugin developed and what is it used for? = The CJT plugin was created to help website authors write their own code. The plugin allows you to contribute to your Wordpress installation code via a simple web interface, where you can modify and extend the functionality and appearance of your website by writing code directly into CJT code blocks. A typical example of using the plugin can include changing the the way a specific Wordpress page is displayed, or making a page more interactive by adding some JavaScript (Dynamic HTML). = What is a CJT 'code block'? = The CJT code block is the basic unit for writing code and to associate it with specific Wordpress requests. = What is the Assignment Panel? = The Assignment Panel is a tabs window, which appears on the right side of the code block editor and is used to assign/apply the code block into specific requests. = Can you select more than one item from the Assignment Panel? = Yes! You can select any number of items you need, there is no limitation regarding this. = Can you assign multiple blocks to the same items from the Assignment Panel? = Yes! It's one of the most useful features that CJT supports as it allows you to manage/split your codes into several code blocks, allowing you to override code in a former (or lower ordered) code block. = What is Pages, Posts, Categories and Custom Posts tabs? = These lists with checkboxes represent all of your WordPress Pages, Posts, Categories and Custom Posts that your entire website contains. It also supports subpages and sub-categories, which you will also find in there. = What is the Auxiliary tab? = As there are a number of requests that are not available as normal Wordpress items (e.g. Pages, Posts, etc) but since it's commonly required and most likely be used, you will find them pre-defined in the Auxiliary tab. In the Auxiliary tab you can find pages like: Home, Blog Index, Author, 404 error, Tag, Archive, Entire website, Front-end, Admin backend and much more! = Is it better to use the URLs tab, or should I select items if found through other tabs? = Pages, Posts, Custom Posts and Categories tabs are created to simplify the assignment process for all types of users. Using URLs is great for fast performance as it requires less time to evaluate/identify the request! However, not all things can be done through the URLs tab. For example, applying a single block to a Category index page and all its sub-categories. = What is the Advanced Expressions tab? = The Advanced Expression tab allows you to fully control what requests to integrate into the code block by using Regular Expressions. In other words, allowing CJT users to define more requests to assign the code block to. = Can I move the blocks around? = Yes by hovering your mouse cursor over the code block title bar until it turns into a four-sided arrow, this allow you to move the blocks. Clicking the block title bar allows you to open and close the blocks. = Is block immediately saved after I clicked 'create' on 'Create New Code Block' form? = Yes! The block is created and saved in your database, to discard the block you've to delete it. = Is block orders immediately saved after drag-and-drop block box? = No! In order to save blocks order you need to press 'Save All Changes' button. = Is block immediately deleted after removed from the blocks list page? = No! After delete block you need to click 'Save All Changes' button. = I'm using the URLs tab and my code is not working? = Make sure you have copied and pasted the Page, Post, or Category URL exactly as it appears in the address bar. For example, you may have inadvertently included an extra forward slash at the end of your URL. = Why use the Footer switch in Location/Hook? = Hook location feature gives you control over the location of outputting the CSS/JS code. This is useful in case overriding another plugins' CSS is required. Also sometimes its better to put your JS code in the footer to avoid slowing down your page load. = I received a weird error, what do I do now? = Sometimes a bug decides to rear its ugly head and when this happens, this is when we need your help. If you receive an error, if it be a PHP error, or some functionality that isn't working for whatever reason, please visit our: [CSS & JavaScript Toolbox website and let us know](http://wordpress.org/support/plugin/css-javascript-toolbox) == Screenshots == 1. Main CJT Free code block screen 2. CJT Shortcode button == Changelog == = 6.1.2 = * Fix: Break Wordpress frontend page pagination by issuing 301 redirect. = 6.1.1 = * Fix: Validate block name when editing and adding blocks. * Fix: Code Blocks is not being applied on WPEngine servers and other servers related to the MYSQL query error. * Fix: Load block code one time after its first time opened as it was loaded every time the block is opened. * Enhance: Show User-PHP code errors only when WP_DEBUG is set to TRUE. * Enhance: Auto-Size edit-block-name text field to fit the current block-name, therefor display the name without the need of moving the cursor to the end. * Enhance: Disable new-block form fields while saving prevent user from duplicating block when traffic is slow. = 6.1 = * Enhance: Initially don't load Block assignment panel items: Speed up Blocks page loading time when its initially opened, also affect the browser performance as the items is not loaded or rendered before its required. * Enhance: Initially don't load Block code for the closed/minimised Blocks: Loading those Blocks will be done through AJAX once the Block is opened by user. * Enhance: The ability to 'Cancel' revision mode and get back to the normal mode without refreshing the whole page. * Update: Animate Block 'Save' button for not-saved Blocks. * Update: The Assignment-Panel is now Loads the assigned items only when enter the revision and backup modes. * Update: Set assignment-Panel Advanced-TAB as the default active TAB. * Add: Few helper links to the CJT official website at the top of the Blocks page. * Fix: Block 'Save' and 'Save All Changes' buttons are stay enabled after updating Block Assignment-Panel items and revert them back again. The buttons is enabled even if the Block content has not been changed. = 6.0.15 = * Enhance: Uninstaller is now configurable so that admin can specify is to wipeout the data or not! This is really great for manual upgrade to the PE versions! = 6.0.14 = * Add: Accept Shortcode parameters and segments. Provide PHP framework for code blocks to define, validate and reading Shortcode parameters. * Add: Allow using block 'name' in additional to 'id' when using Shortcodes. * Fix: Failed to work with non-ascii (e.g Arabic) characters. * Enhance: Viewing block info is now showing Shortcode using block 'name' instead of 'id'. * Enhance: Embedded Shortcode with its closing tag as the Shortcode content is now being used by the handler blocks. * Enhance: Revert block Shortcode 'force' parameter default value to 'true' therefore allow using multiple Shortcode for the same block without setting 'force' attribute. = 6.0.13 = * Fix: CJT hijacks Plugins page after activate or deactivate a Plugin. = 6.0.12 = * Fix: PHP code is not getting evaluated when CJT code Block delegated using Shortcode. = 6.0.11 = * Fix: Add ACE Editor PHP Worker as it was missing. * Enhancement: List only Public Custom Posts that can be accessed through Wordpress URL under Assignment Panel Custom Posts Tab. Therefor enhance performance for sites that has 'Log' custom post that might has hundreds or records read for every code block. = 6.0.9 = * Enhancement: Suppress PHP errors displayed under STRICT PHP configuration like PHP >= 5.4.x and therefor boost performance, increase result and security reliability! * Fix: Installer operations state is cleared after the install/upgrade is interrupted, cause the repeats/re-executes of the install/upgrade operations. = 6.0.7 = * Fix: textarea HTML tag break down CJT Block code. = 6.0.6 = * Fix: Conflict with other Plugins! * Fix: Javascript exception thrown when dismissing the install/upgrade notice. * Enhancement: Disallow (with user notice) upgrade/downgrade if the target version is not being supported, therefor saving user data! * Enhancement: Don't break down the site if manual upgrade/downgrade process is uncompleted! Allow user to revert back manually or disable the Plugin. * Enhancement: E_ALL complain! Suppress all notices when WP_DEBUG set to true, allow better development, fast performance and error handling. = 6.0 = * Core code is 100% re-written for optimum performance and future enhancements, and is 100% based on MVC (Model–view–controller) design. * 100% Using Web 2.0 * Applying code blocks to the requests are now enhanced to boost performance. * The ability of interacting with admin pages too - not only the website side as in the previous versions. * Light-weight and smart user-interface. * Multiple operations can be executed at a time! For example, you can work on a code block while another block(s) is saving. * Code block data is automatically revisioned after saving. * Hot Key added for saving code block. * Empty blocks can now exist. * Interaction with each code block from a simple smart graphical Toolbox using Web 2.0 * Delegate code block using Shortcodes. You can do that manually or through CJT smart TinyMCE dropdown list button. * Integrate ACE Editor to provide syntax highlighting and correction while writing codes! * Syntax highlighting for 4 languages: CSS, HTML, JavaScript and PHP. * Entire plugin is now extensible! CJT supports installed extensions to extend or enhance its features. * Batch operations (Toggling On and Off, Activate, Deactivate and Revert states, Delete empty and Delete all) toolbox allow for batch update of all code blocks. * Rename and save code block name. * You can now save multiple backups. * Activate and Deactivate code blocks feature. * Fix: blocks order was correctly displayed from the admin side, but had no effect while applying blocks to the website side. * Templates system is totally removed and will be presented with many enhancements via a separate extension. * Allow assigning code blocks to Posts and Custom Posts. * Apply 'Category' block to all the child posts (or sub-posts) within that category. * Assignment Panel smart feature to assist while working with hierarchical items (sub-pages, sub-categories, etc). * Auxiliary tab has been added to the Assignment Panel in order to organise all the predefined items (or requests) under a single tab. * Moved and added: 'Front Page', 'All Pages' and 'All Posts' predefined items to appear under the Auxiliary tab. * Newly defined: Blog Index, All Categories, Recent Posts, Entire Website, Website Backend, Search Pages, All Archives, Tag Archives, Author Archives, Attachment Pages and 404 Error, which are listed under the Auxiliary tab. * Support of regular expressions for defining code block Point-To-Hook * Security enhancements, only administrators can execute CJT backend operations. * Each block has an Information metabox (Author, created date, modification date, and Shortcode). * Create new block with initial properties (state, name and position). * Internal error detection routine for detecting Ajax errors that may have happened away from users view. * There is an extensive CJT User Manual PDF file attached in the /docs folder. You can also download this file through the website - click for [CJT Free User Manual](http://css-javascript-toolbox.com/css-javascript-toolbox-free) * Use of a separated Dashboard item to embrace all CJT plugin pages. * Added separate installer and upgrade pages for both CJT v0.3 and v0.8 to allow watching of the installation processes. * Added an uninstaller to completely erase all CJT data from the system. * 100% tested and working with BPS (BulletProof Security) plugin, after applying [simple Ajax bypass rule](http://css-javascript-toolbox.com/support/topic/bulletproof-security-ajax-issue-and-resolution-2) = 0.8 = * Modifying template code. * Header and footer hooks support so you can select which hook to output CSS/JS code. * Code blocks can be reordered. * Code blocks can now be given names that can be edited and saved. * New icons and improved UI. * Multilingual support: Only English translation is shipped with this version. * Style overriding: code blocks order will allow any higher-positioned blocks style syntax to override lower-positioned blocks style syntax. * Embedded Scripts: Embedded WordPress or Scripts that are shipped out with CJToolbox plugin by just checking them. * Backup and Restore blocks data. * Bug Fix: New code blocks are not toggling unless the page is refreshed. * Bug Fix: CSS/JS template extra slash character problem. * Bug Fix: Code block deletion issues. * Bug Fix: Code is not applied to the URL list except the last URL. * Bug Fix: Cannot use string offset as array error. * Bug Fix: Invalid argument supplied foreach() error. = 0.3 = * This is the very first release. == Upgrade Notice == = 0.8 = Its recommended to backup your database before upgrading. Templates feature/system is not available anymore! Please backup your templates data manually before upgrading. You can do this by copying and pasting CSS and JS template data into a text editor and saving your text file. If you have any other third-party plugin or software integrated with the CJT plugin database, please note that the database structure has been completely changed in CJT Free. Linked scripts are now obsolete! If you've linked scripts with any code blocks, then those blocks might stop working. = 0.3 = Its recommended to backup your database before upgrading. Templates feature/system is not available anymore! Please backup your templates data manually before upgrading. You can do this by copying and pasting CSS and JS template data into a text editor and saving your text file. If you have any other third-party plugin or software integrated with the CJT plugin database, please note that the database structure has been completely changed in CJT Free. Code block names will get changed as 'CSS & Javascript Block' phrase will be removed and replaced by 'Block' word. The double-slashes fix modules is now obsolete! If you have extra slashes (double slashes) in your code block you have to clean it manually yourself or upgrade to version 0.8 to fix them first! == Credits == Copyright © 2013, Wipeout Media. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.