I recently had a situation where I wanted to run multiple installations
of farcry in subdirectories under a single hostname.  Using an old
e-mail exchange I found online
(http://qaix.com/content-management-system/289-753-it-works-was-re), I
was able to get this working just by editing the apps.cfm file.  A
sanitized sample of my new apps.cfm file is below:

<cfscript>
stApps = structNew();
switch( ListFirst( CGI.SCRIPT_NAME, "/" ) ) {
        case "subdir1":
                stApps['www.example.com'] = "farcryapp1";
                break;
        case "subdir2":
                stApps['www.example.com'] = "farcryapp2";
                break;
        }
</cfscript>

This seems to work fine (although I would welcome input from anyone who
knows of a problem with this approach), but I believe the apps.cfm file
will be overwritten by the installer script if I try to add a third
installation of farcry.

I was thinking that I could submit a patch to the core to solve this
problem permanently.  It seems to me that a relatively small number of
files would need to be updated:

1. The format of apps.cfm would need to be modified to store the
hostname, optional subdirectory, and farcry application path in a data
structure rather than a code fragment.  An XML file seems to be a good
candidate for this, since the functionality to read in, parse, update,
and write out XML files to disk is built in to CFMX.

2. The /farcry_core/admin/Application.cfm and corresponding
OnRequestEnd.cfm files would need to be updated to understand the new
data structure.

3. The installer would need to be updated to read and write the new
data structure.

4. Code would need to be written for the updater script that could read
in the old apps.cfm file and write out the new format.

Would there be support for merging these changes into the official
codebase if I developed them?  Does anyone have any input on this plan
(especially problems I have not seen)?

- Patrick Correia
Clough Harbour & Associates LLP


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"farcry-dev" group.
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/farcry-dev
-~----------~----~----~----~------~----~------~--~---

Reply via email to