That's what I do. In my environment, I've got a development server, and a
production server. In app_globals, I do a <CFIF HTTP_REFERER = ...> so I
know which server is being used, and from within the CFIFs, I set up the
directory information as you state, with vars pointing to physical path
names. This way, the same app, as is, can be swapped between the dev server
and the live server.

Creating pointers to the physical path names works grand for me; it makes
for much more portable code. Quite in fashion with the fusebox philosophy...

Alan McCollough
Web Programmer
Allaire Certified ColdFusion Developer
Alaska Native Medical Center

> -----Original Message-----
> From: Dustin Breese [SMTP:[EMAIL PROTECTED]]
> Sent: Tuesday, December 19, 2000 7:06 AM
> To:   Fusebox
> Subject:      RE: the dot notation
> 
> Perhaps a penny short and a few days late, but...
> 
> What do you think about each circut app having a "NAME" which points to
> the
> directory it resides?
> 
> For example, in my APP_GLOBALS file, I set REQUEST.ROOTDIR="/" (or
> whatever)
> and in my APP_LOCALS for the PRODUCTS component, set
> REQUEST.PRODUCTS="#REQUEST.ROOTDIR#/products".  I can use this var
> anywhere
> I need it in the PRODUCTS component and don't have to worry about where
> the
> physical app dir is.
> 
> So, my images would come out as <img
> src="#REQUEST.PRODUCTS#/images/hello.gif">.
> 
> -Dustin
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to