Category Selected:

tutorials

Blog

New WireBox Ref Card Released

Brad Wood |  October 09, 2013

We have just released the latest installment in our series of getting ...

Read More

Tip of the Week: Amazing Interception Points

Brad Wood |  September 23, 2013

One of the most powerful features of ColdBox are interceptors. They follow a publisher/subscriber model that lets you decouple your application code and latch on to keys points in the ColdBox framework. You can create and announce as many custom interception points as you like, but today I want to review the built-in points that the framework provides you.

All it takes is a simple CFC and a line of config code to register a new interceptor, or "listener" that will be invoked any time an interception point is reached that the CFC is listening for. You can run your own auditing, logging, or re-route the request. Please skim through these and keep them in mind as you build your ColdBox applications.

Read More

New Blog Series on Leveraging Couchbase Server in CFML

Brad Wood |  July 26, 2013

Today the Ortus Solutions blog is starting a new series on how to leverage Couchbase NoSQL from ColdFusion and also releasing some great new products under the Ortus stack throughout our series.  We'll being showing how to install Couchbase...

Read More

Tip of the Week: Change Your Default Reinit and Debug Mode Passwords

Brad Wood |  July 22, 2013

This week's tip is a simple reminder to check your ColdBox config and ensure that you've changed your reinit and debugMode password for all externally-available sites to be something other than the default.

Out-of-the-box, ColdBox can be reinitialized with the following:
site.com/index.cfm/fwreinit=1

While there's nothing inherently dangerous about that, reinitting can be a costly operation that flushes caches and re-load...

Read More

Tip of the Week: Using JavaLoader in WireBox

Brad Wood |  July 05, 2013

If you're using external Jar files in your project, you may be loading them at run time with Mark Mandel's JavaLoader project.  (CF10 allows for dynamic loading of Jar files, but for people still on CF8, or 9, JavaLoader is the defacto method)
If you're manually creating and using the JavaLoader CFC, please remember that WireBox has a dedicated "JavaLoader" namespace in its mapping DSL to handle this for you using ColdBox's JavaLoader Plugin.  Here all you have to do:

...
Read More

Tip of the Week: Enabling Event Caching

Brad Wood |  May 23, 2013

An important piece of a well-performing application that can scale under load is caching.  This can (and should) be implemented at multiple levels.  CacheBox is an enterprise cache API and aggregator that can be used stand-alone and comes bundled with the ColdBox framework.  ColdBox has some nice hooks to allow you to utilize CacheBox in several ways with very little work and Event Caching is one of those ways.

Event Caching gives you the ability to cache the result o...

Read More

Tip of the Week: What is a Soft Reference Cache Anyway?

Brad Wood |  May 07, 2013

CacheBox contains a number of different cache providers ranging from EHCache to Railo's Memcached.  There is also a provider implemented in ColdFusion simply called the "CacheBox Provider" and two of it's stores are the ConcurrentStore and the ConcurrentSoftReferenceStore.  You may have wondered what the "soft reference" part means and why you would want to use it.  If that's you, here's some history and explanation.  

In Java, Whether or not an object is garbage...

Read More

Tip of the Week: Superclass is Optional For Handlers, Plugins, and Interceptors

Brad Wood |  April 24, 2013

In ColdBox, Event Handlers, Interceptors, and Plugins are represented as CFCs.  You are probably used to their signatures looking like this:

myhandler.cfc
component extends="coldbox.system.EventHandler"{}

myInterceptor.cfc
component extends="coldbox.system.Interceptor"{}

myPlugin.cfc
...

Read More

Tip of the Week: Using the AntiSamy Plugin to Clean User Input

Brad Wood |  March 28, 2013

If your site ever displays text on the page that end users have control over, you should be concerned about XSS attacks.  This could come in the form of user comments at the bottom of an article, user-generated content, or user profile information.  In many instances, the user should never be entering any HTML and you might simply fully escape that text with HTMLEditFormat() or EncodeForHTML() as you output it.

Other times you may be dealing with a forum or message board t...

Read More

Tip of the Week: Being More Productive with the Query Helper Plugin

Brad Wood |  March 15, 2013

The Query Helper plugin is a hidden gem in ColdBox.  This plugin has a handful of super useful functions you can perform against query objects-- some of which you may have gone out of your way to write on your own in the past, or just simply lived without.  Here a brief list of my favorite functions from the Query Helper plugin that allow you to do sweet one-line manipulations of one or more query objects:

filterQuery
Pare down a result set to only ...

Read More