Could be heavy to load them both at once... may not necessarily
matter, it depends on the traffic and the server...
I would recommend if you're going to reference application structures
like this that you use a function or a CFC to return the appropriate
strings from those structures instead of referencing them flatly ...
i.e. instead of this:
#application.language[request.language].welcomeMessage#
It is probably better to use
#application.textManager.getText("welcomeMessage")#
This way if you need to make changes to the method or to the CFC
internally, you don't later have hundreds of flat references to the
structure in your application that would need to be replaced.
> How about a single application that loads both XML files,
> and stores
> them in application.language.french and
> application.language.english.
> Then based on the URL, set request.language to one of the
> two values
> application.langauge variables, and use that throughout
> your
> application for all your lookup tasks.
> cheers,
> barneyb
> On 6/23/05, Dharmesh Goel <[EMAIL PROTECTED]> wrote:
>> Hello,
>>
>> Am trying to find the best approach for this problem.
>>
>> Application Aim/Need: Display English or French based on
>> URL entered. Application is login based and aim is to
>> store language specific (as well as some config settings)
>> information in Application Scope for an extended period
>> of time. This saves us from going to disk, reading xml
>> file and parsing on every login or every page or every
>> session.
>>
>> CFMX 7
>> one physical directory: c:\wwwroot\app
>> two virtual directories: www.website.com\abc and
>> www.website.com\123
>> both virtual directories point to c:\wwwroot\app
>>
>> Both set of users arrive on login.cfm
>> Based on what website address you use, login.cfm will
>> parse through one of two xml files.
>> www.website.com\abc will pickup english.xml
>> www.website.com\123 will pickup french.xml
>>
>> XML file is parsed through and placed in the Application
>> scope. I need to have two distinct application names to
>> keep both sets of XML data separate. Any tips on how to
>> best accomplish this. I can think of placing a few cfif's
>> in the application.cfm and dynamically setting the
>> application name. But I am not sure if that is advisable.
s. isaac dealey 954.522.6080
new epoch : isn't it time for a change?
add features without fixtures with
the onTap open source framework
http://www.fusiontap.com
http://coldfusion.sys-con.com/author/4806Dealey.htm
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking
application. Start tracking and documenting hours spent on a project or with a
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:210448
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54