[Subject Prev][Subject Next][Thread Prev][Thread Next][Subject Index][Thread Index]

[LI] search and replace using Regular Expressions



Hi friends
To the end of each of these lines i want to append a </a> tag .. 

<li> <a href="http://metalab.unc.edu/javafaq/mailinglists.html";>    Java Mailing Lists
<li> <a href="http://www.mindspring.com/~scdrye/java/faq.html";>     THE SWING/JFC FAQ
<li> <a href="http://java.sun.com/products/jdbc/faq.html";>          JDBC(TM) Technology -

I tried doing this in vi editor and the following regular expression matches the whole line 
/^[a-z<>A-Z0-9/:."'=~()?\-&%# ]*

However when i try to append the contents using the following 
:%s/\(^[a-z<>A-Z0-9/:."'=~()?\-&%# ]*\)/\1<\/a>/gc
it fails

Can any one tell me a way out 
Thanx
Bye
Anand Raman



--------------------------------------------------------------------
The Linux India Mailing List Archives are now available.  Please search
the archive at http://lists.linux-india.org/ before posting your question
to avoid repetition and save bandwidth.