Breadcrumbs in Fusebox 4/5

Posted by Jordan Reiter on Stack Overflow See other posts from Stack Overflow or by Jordan Reiter
Published on 2010-05-13T16:41:18Z Indexed on 2010/05/13 16:44 UTC
Read the original article Hit count: 245

Filed under:
|
|

I'm wondering if anyone has come up with a clean way to generate a breadcrumbs trail in Fusebox. Specifically, is there a way of keeping track of "where you are" and having that somehow generate the breadcrumbs for you? So, for example, if you're executing

 /index.cfm?fuseaction=Widgets.ViewWidget&widget=1

and the circuit structure is something like /foo/bar/widgets/ then somehow the system automatically creates an array like:

[
    { title: 'Foo', url: '#self#?fuseaction=Foo.Main' },
    { title: 'Bar', url: '#self#?fuseaction=Bar.Main' },
    { title: 'Widgets', url: '#self#?fuseaction=Widgets.Main' },
    { title: 'Awesome Widget', url: '' }
]

Which can then be rendered as

Foo > Bar > Widgets > Awesome Widget

Right now it seems the only way to really do this is to create the structure for each fuseaction in a fuse of some kind (either the display fuse or a fuse dedicated to creating the crumbtrail).

© Stack Overflow or respective owner

Related posts about breadcrumbs

Related posts about coldfusion