By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,057 Members | 1,407 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,057 IT Pros & Developers. It's quick & easy.

BBEdit Lite GREP Problem

P: n/a
Hello,

I have several thousand relative links with or without slashes in the
front and already corrected absolute links.

I used this pattern with a slash:

<a href=""/([^>""]*)"">([^<]*) and this was the replace pattern

<a href=""http://www.theherbsplace.com/\1"">

This works fine if the link has no http://mydomain.com/ in front of it
already.

So, I was wondering how I could incorporate a test for

1. not changing the link if the http://mydomain.com/ prefix is present
already
2. no slashes in front of the relative file link and if it is present
perform the update with a slash being added to http://mydomain.com
prefix.

What I found doing the research was the ?! code but my GREP engine
converts it to ?+* and says it is not valid.

Thanks,

Randal

Apr 18 '07 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.