Replace Emails and HREFS with enclosing HREFS in C#
Posted
by Nissan Fan
on Stack Overflow
See other posts from Stack Overflow
or by Nissan Fan
Published on 2010-05-26T07:24:04Z
Indexed on
2010/05/28
20:52 UTC
Read the original article
Hit count: 152
I have an Email body that used to be plain text, but now I've made it HTML. The emails are generated using a number of methods and none of them are easy to convert.
What I have is:
Some content [email protected], some http://www.somewebsite/someurl.aspx.
What I'd like to do is create a function that automatically encloses all email addresses and all URLs withing a string in HREF tags so that the HTML email reads properly in all email clients.
Does anyone have a function for this?
© Stack Overflow or respective owner