don't worry, THERE IS NO simple solution for this problem...
this is where the dedicated programmers excel from the rest...
tip:
for <a href.. tags: you need to consider all these hrefs and more:
href="blabla" <-hrefs with "s
href='234q345' <-hrefs with 's
aaaand... href=dagadfg <-hrefs without 's or "s
take in count the links in frame tags...
oh.. and lets not forget that all of these href strings can come in all size and shapes (HREF href Href <- the last one may be illegal)
and i'm sure there are some that i've left out...
please don't get me wrong, i'm not trying to scare you, but know that there is no easy way... only the right way... but in this case it is really not very difficult, this is a good exercise for many people..
and you don't need regular expression..i don't..
oz
oh yeah, i forgot.. relative urls........................