You can get around this by including the root level Application.cfm file in
your new Application.cfm file

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Antony
Sideropoulos
Sent: Friday, June 20, 2003 2:59 PM
To: CFAussie Mailing List
Subject: [cfaussie] RE: application.cfm


Yes -  an application.cfm in a sub-folder will 'wipe' any higher-level
application.cfm files.

CF searches up the directory structure from the folder that the template
runs in, and keeps looking up the tree until it finds an application.cfm
When it finds one, it stops looking.

>>> [EMAIL PROTECTED] 20/06/2003 14:56:06 >>>
Is that mean if I want to use the application variables defined in the root
level application.cfm in lower level cfm files I have to redefine them in
the lower level application.cfm?


>>> [EMAIL PROTECTED] 20/06/03 14:45:52 >>>

The question was not whether you had one, but where you have it and how does
it get included in your other pages.???
Obviously you do have cfapplication somewhere otherwise it would not work on
one page and not on the other.
-----Original Message-----
From: George Lu [mailto:[EMAIL PROTECTED]
Sent: Friday, 20 June 2003 2:39 PM
To: CFAussie Mailing List
Subject: [cfaussie] RE: application.cfm


Yes, I've got cfapplication tag:

<cfapplication name="Intranet"
    sessionmanagement="Yes"
                sessiontimeout="#CreateTimeSpan(0,1,30,0)#">


>>> [EMAIL PROTECTED] 20/06/03 14:33:27 >>>

Where is your <cfapplication name=""   clientmanagement="yes"
sessionmanagement="yes"   setclientcookies="yes"   setdomaincookies="no"
sessiontimeout="#createTimeSpan(0, 2, 0, 0)#"
  clientstorage="#request.mainDSN#"> initialized?
In what page do you have your cfapplication tag? And is this included
throughout the whole site? Probably best to initialize it in your
application.cfm file.

Taco
-----Original Message-----
From: George Lu [mailto:[EMAIL PROTECTED]
Sent: Friday, 20 June 2003 2:19 PM
To: CFAussie Mailing List
Subject: [cfaussie] application.cfm


Hi,

I've got application variables defined in application.cfm:

<cfscript>
application.root = "/Intranet";
application.dsn = "Intranet";
</cfscript>

I can use these variables in index.cfm and some include files like
LeftNav.cfm:

coding...



<cfoutput>
 <TABLE WIDTH="150" CELLSPACING="0" CELLPADDING="0" BORDER="0">
  <TR>
    <TD>
     <cfif isDefined("request.pageTitle") AND request.pageTitle IS "Welcome
to the Intranet">
    <span CLASS='leftnavon'>Intranet Home</span>
     <cfelse>
    <A HREF="#application.root#/index.cfm" CLASS='leftnav'>Intranet Home</A>
     </cfif><BR>
    </TD>
  </TR>
  <TR>
    <TD BGCOLOR="##999999"><IMG SRC="#application.root#images/spacer.gif"
WIDTH="1" HEIGHT="1" BORDER="0"></TD>
  </TR>
.......

However, when I use them in another include files header.cfm:

coding...



<!--- Intranet header include file header.cfm --->
<HTML><HEAD>
<cfoutput>
 <TITLE><cfif isDefined("request.siteTitle")>#request.siteTitle#<cfelseif
isDefined("request.welcomemsg")>#request.welcomemsg#</cfif>
   <cfif isDefined("request.pageTitle")> - #request.pageTitle#</cfif>
 </TITLE>
 <link rel="stylesheet" type="text/css"
href="#application.root#/_Scripts/styleguide2.css">
</cfoutput>
.......

Coldfusion throws an error:

Element ROOT is undefined in APPLICATION.


The error occurred in C:\Inetpub\wwwroot\Intranet\includes\header.cfm: line
7

5 :                     <cfif isDefined("request.pageTitle")> - 
#request.pageTitle#</cfif>
6 :     </TITLE>
7 :     <link rel="stylesheet" type="text/css"
href="#application.root#/_Scripts/styleguide2.css">
8 : </cfoutput>
9 : </HEAD>



I don't understand why it's working in one template but not another? Please
Help!

Thanks.

(sorry for the long message)

George
---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

MX Downunder AsiaPac DevCon - http://mxdu.com/

AMES (Adult Multicultural Education Services)
www.ames.net.au


Disclaimer
**********************************************************************
This email and any attachments may be confidential.
If received in error, please contact us and delete all copies.
Before opening or using attachments you should check them for viruses
or defects.
Regardless of any loss, damage or consequence, whether caused by the
negligence of the sender or not, resulting directly or indirectly from
the use of any attached files our liability is limited to resupplying
any affected attachments.
Any representations or opinions expressed are those of the individual
sender, and not necessarily those of Adult Multicultural Education
Services (AMES).

**********************************************************************
---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

MX Downunder AsiaPac DevCon - http://mxdu.com/
---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

MX Downunder AsiaPac DevCon -
http://mxdu.com/ -----------------------------------------------------------
-----------------
This email, together with any attachments, is intended for the named
recipient(s) only and may contain privileged and confidential information.
If
received in error, please inform the sender as quickly as possible and
delete
this email and any copies from your computer system network.

If not an intended recipient of this email, you must not copy, distribute or
rely upon it and any form of disclosure, modification, distribution and/or
publication of this email is prohibited.

Unless stated otherwise, this email represents only the views of the sender
and
not the views of the Queensland Government.
----------------------------------------------------------------------------


---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

MX Downunder AsiaPac DevCon - http://mxdu.com/

AMES (Adult Multicultural Education Services)
www.ames.net.au


Disclaimer
**********************************************************************
This email and any attachments may be confidential.
If received in error, please contact us and delete all copies.
Before opening or using attachments you should check them for viruses
or defects.
Regardless of any loss, damage or consequence, whether caused by the
negligence of the sender or not, resulting directly or indirectly from
the use of any attached files our liability is limited to resupplying
any affected attachments.
Any representations or opinions expressed are those of the individual
sender, and not necessarily those of Adult Multicultural Education
Services (AMES).

**********************************************************************
---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

MX Downunder AsiaPac DevCon - http://mxdu.com/
---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

MX Downunder AsiaPac DevCon -
http://mxdu.com/ -----------------------------------------------------------
-----------------
This email, together with any attachments, is intended for the named
recipient(s) only and may contain privileged and confidential information.
If
received in error, please inform the sender as quickly as possible and
delete
this email and any copies from your computer system network.

If not an intended recipient of this email, you must not copy, distribute or
rely upon it and any form of disclosure, modification, distribution and/or
publication of this email is prohibited.

Unless stated otherwise, this email represents only the views of the sender
and
not the views of the Queensland Government.
----------------------------------------------------------------------------



AMES  (Adult Multicultural Education Services)
www.ames.net.au


Disclaimer
**********************************************************************
This email and any attachments may be confidential.
If received in error, please contact us and delete all copies.
Before opening or using attachments you should check them for viruses
or defects.
Regardless of any loss, damage or consequence, whether caused by the
negligence of the sender or not, resulting directly or indirectly from
the use of any attached files our liability is limited to resupplying
any affected attachments.
Any representations or opinions expressed are those of the individual
sender, and not necessarily those of Adult Multicultural Education
Services (AMES).

**********************************************************************


---
You are currently subscribed to cfaussie as:
[EMAIL PROTECTED]
To unsubscribe send a blank email to
[EMAIL PROTECTED]

MX Downunder AsiaPac DevCon - http://mxdu.com/

---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

MX Downunder AsiaPac DevCon - http://mxdu.com/


---
You are currently subscribed to cfaussie as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

MX Downunder AsiaPac DevCon - http://mxdu.com/

Reply via email to