oops, just realized.....that's the file not the directory...got over-zealous..sorry bout that.....
-----Original Message-----
From: Adams, Frank [mailto:[EMAIL PROTECTED]
Sent: Monday, April 05, 2004 9:40 AM
To: [EMAIL PROTECTED]
Subject: RE: [ cf-dev ] Current Directory

try this on for size: <CFSET thispage="#GetFileFromPath(GetTemplatePath())#">
 
Frank
-----Original Message-----
From: James Buckingham [mailto:[EMAIL PROTECTED]
Sent: Monday, April 05, 2004 9:41 AM
To: '[EMAIL PROTECTED]'
Subject: RE: [ cf-dev ] Current Directory

Thanks for the quick replies guys.

 

Unfortunately neither of them are giving me the result I need as both gave me the following absolute address:

 

www.mysite.com/home/

 

...rather than just the word home.

 

Any other ideas?

 

Cheers again,

James

-----Original Message-----
From: Lucas Sherwood [mailto:[EMAIL PROTECTED]]
Sent
:
05 April 2004 14:09
To: [EMAIL PROTECTED]
Subject: RE: [ cf-dev ] Current Directory

 

This should do it!

 

listLast(GetDirectoryFromPath(GetCurrentTemplatePath()),'/')

 

L.

 


From: James Buckingham [mailto:[EMAIL PROTECTED]
Sent: 05 April 2004 2:10 PM
To: '[EMAIL PROTECTED]'
Subject: [ cf-dev ] Current Directory

 

Afternoon guys,

 

Just a quick question today. How do I find out the current directory that my Cold Fusion file is currently sitting in.

 

For example, if I have a Cold Fusion file called test.cfm at the following address:

 

www.mysite.com/home/test.cfm

 

and I wanted to extract the folder name 'home' from here and insert it into my variable how would I do that?

 

Cheers in advance.

JamesB

Reply via email to