We rely on mappings and virtual directories set up in IIS. Generic multi-site functionality is grouped CFC - mapping to coldfusion CFC directory CustomTags - mapping to custom tag directory _Global - js, css, and shell template files
Each site has it's own local content as well Components Css Includes Javascript Templates etc... But the primary mechanism is to set up a config.cfm loaded in Application.cfc/cfm - here we set or override all site dependant stuff Application.cfcpath - usually set to CFC Application.customtagpath Application.globalpath Application.installpath Application.installurl Application.datasource - DB mapping etc... Darin Kohles, Application Developer [EMAIL PROTECTED] Digital Positions, Inc. 2289 Peachtree Road NE Atlanta, GA 30309 404-351-8878 support phone 404-351-2366 main phone 404-351-4055 fax http://www.d-p.com/ -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Clarke Bishop Sent: Friday, May 25, 2007 5:09 PM To: [email protected] Subject: RE: [ACFUG Discuss] Production vs. Development Directory Structure and Referencing Files This is just the sort of good idea I'm looking for Cameron -- Thanks! Who else, has a good way? Clarke -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Cameron Childress Sent: Friday, May 25, 2007 3:18 PM To: [email protected] Subject: Re: [ACFUG Discuss] Production vs. Development Directory Structure and Referencing Files It kinda depends on what you are doing with your code and how you are doing development, but here is what I do: /approot/ (application root directory) /approot/wwwroot/ (contains front controller index.cfm, and any image / js / css files) /approot/model/ (contains all CFCs) /approot/views/ (contains all .cfm files) /approot/config/ (contains framework specific config files) /approot/docs/ (contains any documentation) /approot/tags/ (cutsom tags) ...etc... Now on the development server, the approot is directly inside my IIS root folder. This allows me to internally reference CFCs like "model.path.to.cfc" without making CF mappings for each one. Pretty much zero configuration on the mappings in dev. In production, I map the /approot/wwwroot directory to be the site's root dir and then create one CF mapping where /approot is mapped to "appname" so that I can still call components using "model.path.to.cfc". This way you only have one thing to configure in production, and zero things to configure in dev. -Cameron On 5/25/07, Clarke Bishop <[EMAIL PROTECTED]> wrote: > > > I have continuously struggled with organizing files and setups between > my production and development environments. > > I'm working with a number of sites, and each of them is usually on a > shared host. On my development machine I have directories for each site. > > Development Production > > webroot/Site1/ / (The webroot for this site) > webroot/Site2/ / (The webroot for this site) > webroot/Site3/ / (The webroot for this site) > > My question is the best way to reference various files with this situation. > Say I've got an /include/ directory that needs to be loaded with pages > in the site's root or in sub-directories. What's the best way to do this. > > One way, I've managed this is to setup a session variable, > SESSION.webroot that gets loaded onAppStart by Application.cfc. Then I > can just reference the directory as #SESSION.webroot#include/filename.cfm. > > It just seems like there ought to be a better way to reference common > directories like include, images, etc. > > What's the best practice? > > Thanks, > > Clarke > ------------------------------------------------------------- > Annual Sponsor - Figleaf Software > > To unsubscribe from this list, manage your profile @ > http://www.acfug.org?fa=login.edituserform > > For more info, see http://www.acfug.org/mailinglists Archive @ > http://www.mail-archive.com/discussion%40acfug.org/ > List hosted by FusionLink > ------------------------------------------------------------- -- Cameron Childress Sumo Consulting Inc http://www.sumoc.com --- cell: 678.637.5072 aim: cameroncf email: [EMAIL PROTECTED] ------------------------------------------------------------- Annual Sponsor FigLeaf Software - http://www.figleaf.com To unsubscribe from this list, manage your profile @ http://www.acfug.org?fa=login.edituserform For more info, see http://www.acfug.org/mailinglists Archive @ http://www.mail-archive.com/discussion%40acfug.org/ List hosted by http://www.fusionlink.com ------------------------------------------------------------- ------------------------------------------------------------- Annual Sponsor FigLeaf Software - http://www.figleaf.com To unsubscribe from this list, manage your profile @ http://www.acfug.org?fa=login.edituserform For more info, see http://www.acfug.org/mailinglists Archive @ http://www.mail-archive.com/discussion%40acfug.org/ List hosted by http://www.fusionlink.com ------------------------------------------------------------- ------------------------------------------------------------- Annual Sponsor FigLeaf Software - http://www.figleaf.com To unsubscribe from this list, manage your profile @ http://www.acfug.org?fa=login.edituserform For more info, see http://www.acfug.org/mailinglists Archive @ http://www.mail-archive.com/discussion%40acfug.org/ List hosted by http://www.fusionlink.com -------------------------------------------------------------
