First let me quote a reply I've got from Peter Jakobsson privately, as he had issues posting to the list. I appreciate his detailed answer and think, others might benefit as well from his post:
---------------------------------------------------------------- Hi Pete For some reason, my reply is being rejected by the Active4D list server, so here it is privately in the meantime .. . > I'd like to know, whether people developing in Active4D/Fusebox today still > follow the procedure outlined in the book "Fusebox- Developing ColdFusion > Applications" I took the plunge with fusebox last year and, as far as books go, I bought "Discovering Fusebox 3 with ColdFusion" (http://www.amazon.co.uk/gp/product/0972078630). I really didn't find it a problem that it's based around Cold Fusion. It's more about Fusebox than Cold Fusion and 90% of it is directly relevant to the Active4D implementation. I couldn't recommend it highly enough. Active4D's implementation is faithful enough to the Fusebox methodology (v3) and naming conventions that it's easy to take examples from the book and directly try them out directly. The minor modifications in syntax needed are fairly obvious. > Are there any special tools available to assist in developing applications > in Active4D /Fusebox? Not so much tools as the general environment. The Fusebox implementation manifests itself as a bunch of libraries that directly implement the Fusebox methodology. These abstract away all the "plumbing" you normally have to do to just to get to the point where you can start to write business logic code. (e.g. reading query parameters without worrying about whether they came from a URL or a form, manage stylesheets, headtags, common templates for output etc.). The textmate plugins for Active4D are essential because they highlight and colour code both html keywords as well as Active4D / Fusebox library methods. > If not, does it make sense to follow this approach anyway and create a > skeleton for Coldfusion and afterwards adopt the code to Active4D Fusebox > syntax? I would study and take-apart the Active4D demo. Almost anything you could possibly want to do, from simple to complex, has a precedent in the Active4D demo which, of course, is Fusebox based. Apart from that, the examples in that book I mentioned above are implementable in Active4D and very instructional. > Any tips for speeding up the setup process of an Active4D/Fusebox skeleton > are welcome. Note that the Active4D implementation already is a "skeleton" in that the code to traverse your circuits, output your layouts, embed your stylesheets and business logic is all done for you. All that's left to do is write your application-specific code. That said, a typical circuit template might consist of . . . - fbx_switch.a4d - fbx_settings.a4d - fbx_layouts.a4d - /controllers (Folder containing act_ and qry_ scripts) - circuit/views (Folder containing your html content, sprinkled with exit fuseactions - XFA's - and references to variables which were populated by the controller scripts - circuit/views/layouts (Folder containing the layout for the circuit) (You can look at the Active4D demo for example of each of these). The main things you need to remember are: - put the "heavy weight" business logic and queries in act_ and qry_ scripts in the circuit "Controller" folder - put the html in "dsp_" scripts in the circuit "Views" folder - if you have a template or sub-template, put it in the layouts folder - manage everything from the switch (i.e. call everything from there using "includes") Another thing that's easy to get lazy about: - try to centralise the XFA's (Exit fuse actions). It took me a while before I even realised what an XFA was (it's a "link" :) ). Fusebox likes you to centralise all your links in the one place (usually fbx_switch or and act_ called from fbx_switch). It's easy to get into the (bad) habit of building the links in the output scripts (i.e. the dsp_ which contains the content html) but actually, the display fuses become very portable if you do it the Fusebox way and create XFA's in a centralised manner. (See Active4D's "fusebox.makeurl" function which lets you do this using the circuit.action notation). Hope that helps for a start. Peter ---------------------------------------------------------------- As Peter and Steve do not have read the book "Fusebox- Developing ColdFusion Applications" I'll give a short rundown of the concept in developing a Fusebox application: 1.) Wire-framing the app. A very rough concept what the application shall do. No direct relation to code or webpages. More kind of brainstorming. 2.) Prototyping the app. A static HTML layout of the final app. "It doesn't do anything but looks like the final thing." 3.) Mind Mapping the app. By examining the exit points (aka links and forms) of the prototype pages a Mind Map is build that is almost the skeleton of the circuits of the final app. It is done in a Mind Map application for speed and the graphical respresentation it gives you. 4.) Fuseminder is an application, that takes the text export of the Mind Map app and automatically generates the circuits with the correct nesting. For smaller Fusebox apps this probably is a bit of overkill. For really big applications with a lot of interaction, this might make it easier to define the necessary circuits. Anyhow, I think I follow the route Aparajita recommended and build a generic circuit folder structure and us this as a template. @Peter: I don't see any layouts folder in the Active4D demo. All output is done in the "dsp_" scripts. What do you mean exactly, when you speak about a template or sub-template? Are these static includes for the dsp_ files? @Steve: Thanks for the upload. The diagram is actually from the wiki: http://wiki.aparajitaworld.com/w/page/11287710/A4D-Fusebox-Flow @Aparajita: Browsed through the mailing list for posts about the Textmate bundle and the last one was this http://active4d.2283328.n4.nabble.com/new-TextMate-bundle-tp2960979.html where you mentioned, "New circuit" would have been fixed now. Thus I assumed, it is me not using it correctly. ;-) Pete _______________________________________________ Active4D-dev mailing list [email protected] http://list.aparajitaworld.com/listinfo/active4d-dev Archives: http://vasudev.aparajitaworld.com/archive/active4d-dev/
