I'm stucked in a bigger problem. This is a very simplified version of themy problem. Suppose I have a text file containing at several places the code 20091a or 20092a or 20093a. I'm wishing to surround all thesethis code by the text surrounded with <code></code>. So finally theythe resulting strings above would becomebe like 20091a<code>20091a</code> or 20092a<code>20092a</code> or 20093a<code>20093a</code>.
In summary, my question,So how do I replace the search text with a text containing the search text.? Is there any variable which holds the search text so that I could use something like :%s/2009.a/<code>$SEARCH_TEXT<\/div>?