Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Shared Application.cfm files

New Here ,
Oct 19, 2011 Oct 19, 2011

I have multiple sites set up for different countries/languages. The sites are virtually identical, except for the content; and I am reusing as much code as possible. Each site is set up as follows:

site    >>    server path

http:\\www.[domain].com   >>  c:\web\us\

http:\\www.[domain].de  >> c:\web\de\

http:\\www.[domain].fr  >> c:\web\fr\

etc...

Is there any issue with using a single Application.cfm file at the root of c:\web, as opposed to using separate identical Application.cfm files for each site?  In case you are wondering, yes I am still using Application.cfm but considering updating to Application.cfc.  Does that change the answer to my question?

563
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guide ,
Oct 20, 2011 Oct 20, 2011
LATEST

I'm not sure whether Application.cfm supports extending, I wouldn't have thought so as it's not a cfc. The way to do it is to have an Application.cfc in the root which does all you want it to do, then all the subdirectories extend that, i.e. <cfcomponent extends="Application.cfc">.

You might need to use the ApplicationBase method, Google around and you'll find it. But that's the way to go. And yes, you should definitely change to App.cfc.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources