Hey guys...

 

Thanks... I think I figured it out. I was trying to make it way to complicated.

 

Using the code below does what I need.

 

<cfset user = ListFirst(CGI.URL,"/")>

<cfset page = ListFirst(user,".")>

 

Not sure if this is the best way but it works...

 

Thanks,

- Neal

 

-----Original Message-----
From: Matt Robertson [mailto:[EMAIL PROTECTED]]
Sent
:
Thursday, October 30, 2003 11:40 AM
To: CF-Talk
Subject: RE: Striping URL

 

Way overcomplicated but it works and I've gotten lazy just plugging it
in as an include.  There's gotta be an easier way, and Critter's
certainly looks like the ticket if you know the extension is 3 chars.

Anyone know a better way if you don't know the file extension length
(i.e. '.html')?

<cfset variables.FileStrip=
Left(Reverse(cgi.Script_Name),(FindOneOf("/",Reverse(cgi.Script_Name),1)
-1))>

<cfset variables.TheNameOnly=
Reverse(RemoveChars(variables.FileStrip,1,FindOneOf(".",variables.FileSt
rip,1)))>

----------------------------------------------------------
Matt Robertson   [EMAIL PROTECTED]  MSB Designs, Inc.
----------------------------------------------------------
An unbreakable toy is useful for breaking other toys.  
- Helpful Hints


[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]


Reply via email to