This is actually not a good time for regular expressions, though you could certainly use them. Assuming the entire text is in a single string, might I recommend the concatenation operator?
If you really want to use a regular expression, a substitution using the $ and ^ metacharacters as well as the s modifier will work. Give perlre a read through.
In reply to Re: Adding <pre> at beginning </pre> at file end
by kennethk
in thread Adding <pre> at beginning </pre> at file end
by vinoth.ree
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |