Skip to main content
tej_web
Inspiring
May 18, 2009
Answered

Trim URL from the right side.

  • May 18, 2009
  • 1 reply
  • 774 views

Hello all,

I am trying to trim the right side of a URL base on the first occurrence of "\".                      

Note: URL is a Verity search result.

The URL example: "C:\Inetpub\wwwroot\Conv_PDF\Files\facility \ facility_ur_plan.doc "

If I use           cfset tString = #right(#URL#,  20)#

I get the result of  "facility_ur_plan.doc"

What I would like to do is find the first " \ "starting from the right side and this use the result as the cut point of the Right function.

ex: cfset tString = #right(#URL#,  #cut#  )#

This would allow any length of a document name to be used.

Any ideas would help.

Thank you

TJ

This topic has been closed for replies.
Correct answer mack_

]]>

Mack

1 reply

mack_Correct answer
Participating Frequently
May 18, 2009

]]>

Mack

tej_web
tej_webAuthor
Inspiring
May 18, 2009

Thanks Mack,

That did the trick !

TJ