New Search

If you are not happy with the results below please do another search

58 search results for:


Hello World Package

Hello World package is a simply package to explain how a very simple package can be created. Hello World Package is define the following: Block: Display a text that is taken as Block Shortcode Parameter. Template: Style the displayed text. readme license Template Code h1.hello-world-text {font-size: 24px; color: red} Block Code <h1 class=”hello-world-text”> <?php // Display text […]


Attach Images

Attaching images to Template can be very useful when a Template of type CSS need to link to images. Attaching images can be done via folder tag as following: <folders path=”PATH/TO/ALL/CHILD/FOLDERS”> <folder path=”FOLDER_PATH_TO_UPLOAD” /> </folders> folders tag allows to group a set of related folders without repeating the path on each on of them. Multiple folder tags […]


Pointing to file

Pointing to file is to point to a package file located inside the package from the definition.xml file, so that package process can locate those files and loading them Point to Block code File named block.php located in the package root folder. <object type=”block”> <code locate=’file’>block.php</object> </object> Point to Block code File named block.php located […]


Define Groups

Group is used to group a set of parameters together. It has no logical affects however it will be used by the Form to display each group as set of parameters. Creating group can be done by using group tag. Its possible to create multiple groups with no limitation. <group> <name>NAME</name> <description>DESCRPTION_TEXT</description> </group> Data Fields NAME: Used as […]


Link Template

Linking Template to a Block can be done through package definition XML file via link tag. Link multiple Templates can be done by using as many link tags as needed. link tag must be presented under the root links tag as following: <object type=”block”> <links> <link name=”TEMPLATE_NAME_1″ /> <link name=”TEMPLATE_NAME_2″ /> <link name=”TEMPLATE_NAME_3″ /> </links> </object>


Input Types

CJT Block Shortcode parameters form is provide a few Input Types to be used for talking user inputs. Its mean the Input Field Type to be used for getting user Inputs. For example Boolean Parameter might use either Checkbox or (Yes/No) Dropdown list! This is up to the package author to define which type to […]


Data Types

Parameter Data Types is used by CJT Shortcode Block parameters form for validating user inputs and generating Shortcode Parameters Text/String. The following Data Types are being supported by CJT. Native/Primitive Data Types boolean: Accept String true/false or numeric 1/0. number: Accepts any numeric value text: Accept String data. raw: Same as the text data type except that when generated as Shrotcode, it won’t wrapped […]



Define Block Shortcode Form Parameters would inform CJT to carry up few steps based on the current process. Two process is being handled when using Block Shortcode with parameters based. Insert Shortcode Get user Inputs through internal Parameter Form Validate Parameters value based on the Parameter Data Type Generate Block Shortcode text. Process Shortcode Read […]


Shortcode Parameters Form

One of few features is only available via Packages and currently cannot be achieved using Windows! Shortcode parameters form is CJT internal form used to prompt for Block parameters when inserted as Shortcode via TinyMCE shortcodes list. Parameters also might be passed directly by writing the Shortcode manually however PRO edition helps using simple form […]


Basic Structure

The basic valid structure of the definition.xml file is as following: <?xml version=”1.0″ encoding=”utf-8″ ?> <package xmlns=”http://css-javascript-toolbox/xml/namespaces/cjt/6/package”> <name>PACKAGE_NAME</name> <description>DESCRIPTION</description> <author>AUTHOR_NAME</author> <webSite>PACKAGE_WEBSITE</webSite> <license>RAW_LICENSE or LICENSE_FILE</license> <readme>RAW_README or README_FILE</readme> <objects> OBJECT LIST GOES HERE … AT LEAST ONE BLOCK OBJECT SHOULD BE PRESENETED …. …. …. …. </objects> </package>


Package info

The following tags are currently supported for the Package. All of them are being displayed in the Packages Table List. name: Use to identify the package. description: Package description text. author: Package author name. webSite: license readme <?zml version=”1.0″ encoding=utf-8″ ?> <package xmlns=”http://css-javascript-toolbox/xml/namespaces/cjt/6/package”> <name>NAME</name> <description>DESC</description> <author>AUTHOR</author> <webSite>WEB SITE</webSite> <license> <readme> … … … … </package>


License file

Attaching license file for the package script is great for developers like to publish/share their CJT package scripts with others. Defining a license for the CJT Package script is defining by license tag. License can be either of raw text inside the Definition XML file or independent package text file. RAW License <license> <![CDATA[ … LICENSE TEXT […]


Readme file

Attaching readme file for the package script is great for developers like to publish/share their CJT package scripts with others. Defining a readme for the CJT Package script is defining by readme tag. Readme file can be either of raw text inside the Definition XML file or independent package text file. RAW readme <readme> <![CDATA[ … README TEXT […]


Define Template

Like creating new Template via user Interface its possible to create new Template by writing definition.xml file command/tag that instruct CJT to create new Template. Templates must be defined first before Blocks. Linking Block to Templates is not being created yet would cause the package installer to fail. Creating Template can be done by using <object> tag. object tag […]


Define Block

Like creating new Block via user Interface its possible to create new Block by writing definition.xml file command that instruct CJT to create new Block. Only Global Blocks can defined via Package definition file. Block cannot assigned to WordPress pages when created via Package, assignment to page must be done through UI by webmaster. Block […]


Definition XML File

The one file that builds up the CJT Packages. Just like using User Interface for creating Blocks or Templates. User has to click ‘New’ button, Fill the Form, click save and Link Block to Templates if needed. The same operations can be done by writing few keywords to the definition.xml file that CJT Package installer […]



Embedding Templates is simply to Copy the template into the Code Block Editor where in the location of the Editor Cursor. Currently CJT is not adding any Tags to the embedded templates, its simply geta Template copy. If the embedded Templates is then updated later it doesn’t reflect that update to the Code Block as […]


Writing Javascript & CSS Templates

When writing Javascript and CSS Templates it would be considered like writing separated .js or .css files, no <script> or <style> or <link> tags should be added in those templates. Those Tags are being added automatically by CJT Templates linker. Adding those tag would break those Templates. Embedding Template is current will embedded Javascript and […]


WordPress Built-In Scripts & Styles

CJT Template Lookup allows WordPress built-in Scripts and Styles to be linked or embedded to Code Blocks. Its one of the powerful features that CJT Template Lookup is providing for Blocks. Almost there is no Third-Party script is not depending on some famous scripts like jQuery. CJT user don’t have to add those manually or copy their […]



Its the most useful feature provided by Templates system. Linking Template is to Import Template into one or more Code Block. The method of how the Template would be linked by CJT is based on the Template Type/Language. Each Type is linked differently. We’re going to show how each type would be linked. HTML & […]



Linking Template can be used when centralizing a peace of code is required. As Multiple Code Blocks can be linked to the same Template file its force a centralisation as those all code Blocks is being use one Template file. Updating Centralised Template file is always reflected to the Blocks so there is no need […]



Template Types is to tell CJT what Language specifications (Syntax Highlights, Error Checker, etc…) and also tell Template Linker of how to link this Template. Finally its used by the Template Author for identifying different type of scripts (Javascript, CSS, etc…). Different types would be handled differently while its being linked. Currently, CJT is support the following […]



Deleting Template is to remove the Template record from the database and also unlink it from all the Block that being linked this Template. This is it! Embedded Template is getting a copy from the template code and pasting it to code Block and deleting Template has no effect on embedded templates. Only linked Blocks […]


Install / Uninstall

Install Installing CJT Package is to instruct CJT Package process to load the package definition.xml file and create all Objects (Blocks, Templates, Parameters, etc…) Currently, after installed the package cannot be downloaded or upgraded. The package can only installed or uninstalled. For upgrading package it should be uninstalled and installed again. CJT Packages is still […]



Creating a template is a very easy process that required few fields to be filled. Name: Require template name that would be used when link/embedded templates through Templates Lookup. Please keep the name clean, brief and descrbing the Job of the template. Once the template is created this field cannot be changed. Language: Require template language to […]



Packages is a set of CJT Blocks and Templates files added to a ZIP package and defining by the package definition.xml file. The idea behind the package is to allow sharing a peace of codes between two CJT users or between two CJT servers that all would use the same Blocks/Templates. A typical package contain one […]


Load For Edit

Initially all closed Global Blocks are in the unloaded state until they are opened. When it changes into the open state, it will then be loaded from the server. This means when you go into the main CJT block management page, all closed blocks are still not loaded from the server. Only basic details that identify […]



In a case where there is a Global Block assigned/associated to a page/post that already contains a Metabox Block, then the Metabox Block will get higher priority over the Global Block. So that the Global Blocks those assigned to the Post is getting in the queue before the Metabox Block that’s give the Metabox Block […]



Deleting a Metabox Block is to remove the internal link/association between the block and the page or post that it is associated with. It would also delete all of your database records that are related to the block. As long as a Metabox Block is not required any more, it is recommended to delete them […]



By default CJT is not associating or creating a Metabox Block for WordPress pages/posts until it is created by the user. This is ideal for performance as it saves database processing, server memory and page loading time. Instead of creating a full Metabox Block for every WordPress page/post, CJT is placing a ‘creation block’ from […]


Advanced Code Editor

CJT comes with an Advanced Code Editor that supports many languages, which is a necessity these days for almost all WordPress users. Syntax highlighting for four languages (i.e. CSS, HTML, JavaScript, PHP) Over 20 editor themes (GitHub, Eclipse, Chrome, Textmate, etc – more can be imported) Automatic indent and outdent Handles huge documents (four million lines […]



Template is a peace of reusable code that can be embedded or linked to code Blocks, Global or Metabox Blocks. Unlike code Blocks that is just created to do specific function by assigned to specific requests. Templates is to be used by Code Blocks as Code Libraries that might be required to be used by […]


Writing Code

Writing code is the step taken within the code editor window of the code block, and is what carries out the functionality that’s intended to be performed by the block. CJT is providing users with a number of tools for writing code. One of these powerful tools is the Advanced Code Editor (ACE) with syntax […]


Metabox Blocks

A Metabox Block is a CJT block that is assigned to one single WordPress page or post. This type of block cannot be assigned to multiple items (i.e. pages/posts) at the same time. The main visual difference between a Metabox Block to a standard Global Block is a Metabox Block does not have the Assignment […]


Using Expressions (Advanced)

When to use? In some cases, users might need to cover more areas/requests where the assignment items fall short. This is when Expressions can be used and passed to the CJT Assignment Panel. What kind of Expression is it? CJT currently supports only Regular Expression as PHP, except that you don’t need to write the […]


Assign to URL

When to use? As in some cases, users might need to cover more areas/requests where the assignment items are just not enough. URLs can be passed through the CJT Assignment Panel. CJT URL parser accepts a list of URLs separated by a newline. so each line would have the full URL you wish to use. […]


Assign to Custom Posts

As most WordPress sites almost always have some form of custom posts (Products, Downloads, etc) created by using other plugins and themes, CJT supports assigning Global Blocks to custom posts. Custom posts might be hierarchical like WordPress Pages or flat like WordPress Posts. CJT is able to detect the custom post type and list it hierarchically […]


Auxiliary Assignments

Auxiliary assignments are predefined assignments that group some common WordPress request types. When assignments are required for cases where: the request currently exists AND the request does not yet exist, then it would be a good idea to use Auxiliary assignments. Auxiliary assignments give you the option of assigning a block to WordPress request items (e.g. […]


Assign to Category

Why Assign to a Category? By assigning a Global Block to a category, you are applying the block to the category Archive (index) page and all the posts laying under that category! Yes, this is it. The idea behind applying blocks is to include all the child posts. When assigning a block to a category, only […]


Assign to Post

Assigning single/multiple Posts As the nature of WordPress Posts are flat (non-hierarchical), the assignment is straight-forward to the post itself and doesn’t include any other posts or categories that the post is related to. The Post tab in the Assignment Panel provides you with the entire list of all existing posts in a flat, non-hierarchical […]


Assign to Page

When assigning a block to a page, only that page would get the block applied. It doesn’t include the child pages automatically by default. This is intended so users can get more control by selecting the child pages (sub-pages) manually. Applying a block to all the child pages can be a problem if a few pages in […]


Assigning Global Block to Request

CJT is basically built over the assignment/association feature that allow users to run their codes in parallel with WordPress requests. A single Global Block might be assigned to multiple requests at the same time. This feature can be done through the Assignment Panel window. The Assignment Panel can be classified into three parts: WordPress (Posts, Pages, […]


Restore To Revision

Each time Block is saved a new revision would be created by taking a snapshot from the Block fields. The following list represent the fields that are being copied while creating Block revision: Code Assignment Panel So when a new revision is being created the Block code and all the assignment panel (Pages, Posts, Custom […]


Using Shortcode

Every created CJT Block is automatically assigned a Shortcode that can be used from WordPress Posts. Block can be delegated by using [cjtoolbox] Shortcode. If you’re running a PRO edition you can use the TinyMCE button for inserting the Shortcode. Shortcode can delegate the block by either Block Name or Id. As the Id is […]



Global Blocks can be reordered so that the top (higher up) blocks would be executed first before the bottom (lower down) blocks. Ordering Global Blocks can be very useful especially when functionality or output is dependant on the execution order. If for example you need to move a number of bottom (lower down) blocks higher […]


Block Code Execution/Output Location

Output/Execution location is defining where is the code Block is going to be executed or outputted. So that when CJT is preparing the code Blocks it then wait for WordPress signals where those code Blocks should be executed. Currently CJT is using two Location. Header and Footer locations. Header location is being fired by WordPress via wp_head […]


Activate/Deactivate Blocks

In many case it might require to Activate/Deactivate or Enable/Disable a few code Blocks as those Blocks is not ready at the moment or for other debugging purposes. Activate/Deactivate code Blocks can be very handy in many situation if preserving the code Block is required however only the functionality is need to be stopped for […]


Block Types

CJT provides two types of code block – Global Block and Metabox Block. Global Block – this occurs in the main CSS & Javascript Toolbox dashboard page, where you can create multiple blocks and assign them to WordPress requests. Global Blocks can even be ordered so that blocks override other blocks. Additionally, blocks can be […]


Edit Block Name

Please keep CJT Block names simple and briefly describe the functionality of the block. It can be very useful for remembering things about the block. The block name is also used as the shortcode name, when adding shortcodes to pages/posts. For editing the block name do the following: Click on the block name An input […]



Deleting CJT Global Blocks can be done by clicking on the Delete (cross icon) from the block main toolbar. You’ll then need to confirm the delete message. After confirming the deletion, nothing actually deletes just yet as the block is only removed from the UI list. You have to click the ‘Save All Changes’ button from […]



Creating a Global Block is a very simple process that can be done by clicking the ‘Create New Block’ button from the CSS & Javascript Toolbox dashboard page. You will have to fill out the Create New Code Block form and click OK. New Block Fields: Name: Block name that will be used for giving a hint […]


Global Blocks

Global Blocks is the Block type that works globally and can be assigned to multiple WordPress requests. CJT Global Blocks can be created through the CSS & JavaScript Toolbox main dashboard. A Global Block has two components that build up the Global Block unit. The Code Editor and the Assignment Panel. The Assignment Panel allows you to assign […]



CJT Code Blocks are the basic unit for writing code and assigning it to specific WordPress requests (e.g. for a Page, Post, Category, Blog index, Expression, etc). It is the main gateway for interaction, allowing users to have their codes assigned. In general, blocks should always be created when you need to assign a piece […]



Fresh install — WordPress Plugins interface Download CJT zip package (for CJT Dev – see purchase receipt) Login to WordPress Dashboard Open Plugins page Upload the zip package and Activate the plugin Click on the CSS & JavaScript Toolbox Dashboard menu and follow the admin notice on the TOP to complete the installation process Fresh […]


What is CJT?

The abbreviation CJT stands for ‘CSS & Javascript Toolbox’. CJT was originally developed to help users, bloggers, novice and professional developers with integrating code into their WordPress-powered website. It was developed to provide solutions to many common tasks. For example, adding JavaScript snippets or CSS stylesheets into WordPress pages and posts. CJT was designed to […]



The most basic and fundamental task that CJT is developed for, is to allow assigning a piece of code to WordPress pages/posts. Creating a separate small plugin might be a good solution, however the user has to identify visitor requests and find a way to associate the parallel code. Also when reassigning the code to […]