As of now I have option A with 14 clients and it can be very frustrating making changes in that amount of apps for something simple like a CSS change. Option B was my first thought of sessionFacade + HtmlHelper but I just like the concept of ServerFileFilter. I didn't really consider the load it would put on the server as every request would have to go threw cfengine.
Thanks for input I will give this a shot. On a side note just curious if there is any interest in a SASS (http:// sass-lang.com/) added to the HtmlHelper? I've seen this partially in ColdBox and I would like to attempt something similar. On Feb 18, 11:03 am, "Peter J. Farrell" <[email protected]> wrote: > I'm glad you like the engineering behind the dashboard. Let me clue you > in why we are serving files via a Mach-II event-handler. We did this so > people would not have to drop assets (such as img / css / js) into a web > accessible location and therefore simplifying the installation of the > dashboard. > > On the other hand, this approach is much more heavy handed. Now, the > CFML engine is having to process a request not only for the HTML > response, but for each asset. Considering the dashboard itself is an > extremely low volume module in the terms of concurrent users we feel > this to be an acceptable trade off versus performance. > > Your most performant option is let the webserver handle the serving of > the assets instead of having your CFML engine take all the load. > However, you have a couple of options in using the HTMLHelper instead. > > There are two forms of thought when it comes to building an application > in which you end up "skinning" for different clients: > > a) Each client gets their own "version" of the application in memory. > Meaning each client has their own application name and therefore each > "version" is not sharing the same application context. > > b) Each client shares a single "version" of the application in memory > and the "skinning" / "branding" is done on the fly dynamically for each > request. > > It sounds like you are aiming more for option B. So I suggest you do > something like (you might use a session facade - however this is a > stripped down concept): > > <view:script href="#session.thisAppVersionAssetBasePath#/prototype.js" /> > > thisAppVersionAssetBasePath could be something like "/clientA/js/" or > "/clientB/js/" > > This way you can have all the power of the HTML Helper, but dynamically > change the base path for your assets on the fly. > > HTH, > .Peter > > neweller said the following on 18/02/10 09:01: > > > > > After spending some time looking at the dashboard. I must say I was > > really impressed with the concept of the ServerFileFilter and how it > > made CSS and Javascript abstract from the view. On the other hand the > > HtmlHelp also has similar features for injecting inline CSS and > > Javascript but I would like take the concept of ServerFileFilter and > > use it on a global scale. For this I really mean a skinning engine for > > say a catalog. If ServerFileFilter could have the basePath dynamically > > changed due to user information I think skinning would be made simple. > > > Basically might thoughts are to change ServerFileFilter into > > ServerFilePlugin. This would allow the plugin to check the > > sessionFacade before rendering and change it's basePath. This would > > make skinning very simple and you could keep one set of views for > > multiple customers by adding folders to your asset folder. > > > I would like to hear the thoughts from the group on this change. Am I > > missing something on EventFilters or would this be a good direction? -- You received this message because you are subscribed to Mach-II for CFML list. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/mach-ii-for-coldfusion?hl=en SVN: http://greatbiztoolsllc.svn.cvsdude.com/mach-ii/ Wiki / Documentation / Tickets: http://greatbiztoolsllc.trac.cvsdude.com/mach-ii/
