Need help finding and changing a string using Coldfusion

Hi

Using ColdFusion, what is the easiest way to find links like the one below in a web page, and removing the tag so its no longer a link.

The link text, in this case "top executives" needs to stay.  Just don't want it to be a clickable link.

The key here is that all these links will have both the "XYZ" folder and the ".htm" extension, which makes them unique on the page.

I am slightly familiar with regex, but not good enough to do this on my own.

<a href="/XYZ/management/top-executives.htm"><u>top executives</u></a>

Thx

Michael
bigmikey88Asked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Pawan KumarDatabase ExpertCommented:
Try using replace function

REPLACE(yourstring, '.htm' , 'z' )

I am using z , you can use anything. this will the link will be disabled.
0
bigmikey88Author Commented:
Hi Pawan,
Thx for helping

The string I am searching for varies so I think I need to use wildcards.  If so does that mean I need an regex?

For example, I only know the beginning and end of the search string:

<a href="/XYZ/     this part varies              .htm">
0
_agx_Commented:
May want to change the question tags. Since it is really about reg expressions,  tagging it with "Regular Expression" will attract more attention from the regex guru's, not just CF folks.
1

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
ColdFusion Language

From novice to tech pro — start learning today.