Fork me on GitHub

Fusebox

Lexicons

Lexicons are a powerful new feature in Fusebox 5+. They allow you to add new verbs to the circuit.xml language.

Here are some example lexicons which create new verbs in Fusebox 5 that duplicate some standard ColdFusion verbs. They are good examples for anyone wanting to learn to write their own lexicons because they are relatively simple. 

To use the verbs, first download them to a folder named cf inside the lexicon folder in your application. Then add the following extra parameter to your circuit.xml file to tell it about the new namespace:

Then to make use of one of these new verbs (cf:abort for example) you simply write:

Simple Verbs

These verbs stand alone.

abort.cfm
Written by: Nathan Strutz (CF)
This lexicon emulates the ColdFusion tag

cookie.cfm
Written by: Nathan Strutz (CF)
Emulates the ColdFusion tag

dump.cfm
Written by: anon (CF)
Emulates the ColdFusion tag.

lock.cfm
Written by: anon (CF)
Emulates the ColdFusion tag.

timer.cfm
Written by: Qasim Rasheed (CF)
Emulates the ColdFusion tag.

trace.cfm
Written by: Quasim Rasheed (CF)
Emulates the ColdFusion tag.

Nested Verbs

Nested verbs work together to accomplish tasks.

switch.cfm
Written by: anon (CF)
Emulates the ColdFusion tag. Use in conjunction with: case.cfm and defaultcase.cfm

case.cfm
Written by: anon (CF)
Emulates the ColdFusion tag. Use in conjunction with: switch.cfm and defaultcase.cfm

defaultcase.cfm
Written by: anon (CF)
Emulates the ColdFusion tag. Use in conjunction with: switch.cfm and case.cfm

try.cfm
Written by: anon (CF)
Emulates the ColdFusion tag. Use in conjunction with: catch.cfm

catch.cfm
Written by: Qasim Rasheed (CF)
Emulates the ColdFusion tag. Use in conjunction with: try.cfm