Skip to main content
lovewebdev
Inspiring
Mar 8, 2009 7:00 PM UTC
Question

Have Applications.cfm exclude a page?

Is it possible to have your Applications.cfm not run for a particular page.
    This topic is closed to new replies. Start a new post to keep the conversation going.

    3 replies

    lovewebdev
    Inspiring
    Mar 16, 2009 3:55 AM UTC
    Nice. Thank you. I'll try it out. I was waiting for that for a long time.
    Translate
    Participating Frequently
    Mar 16, 2009 3:52 AM UTC
    If you have the pages that you DON'T want the application.cfm to run for in a different directory simply put a new application.cfm with blank content in that directory and it will effectively run 'nothing' instead of the root application.cfm.
    Translate
    Inspiring
    Mar 8, 2009 7:17 PM UTC
    > Is it possible to have your Applications.cfm not run for a particular page.

    Well you could check the CGI.SCRIPT_NAME of the request you wish to exclude
    in the Application.cfm, and run/not run a block of code accordingly. This
    will quickly become unwieldy though, as more and more requests need
    different configs run.

    You're better off organising your application slightly, having separate
    directories / Application.cfms for different requirements.

    Read this:
    http://livedocs.adobe.com/coldfusion/8/htmldocs/appFramework_06.html

    Also, can I recommend you use Application.cfc rather than Application.cfm,
    if poss.

    --
    Adam
    Translate