![]() |
|
|
|||||||
![]() |
PERL - Help needed formatted submit results - Changing data |
|
|
Thread Tools | Search this Thread |
|
|
#1 |
|
Hi all, another area I could use some help with is changing submitted data
based on the data conditions ... I will elaborate. I have a form textarea where a user can type in some text. This text is sent to a perl script that eventually will send that data to someone by email in HTML format. Here is where I need some help. If a user was to type in a web address www.mysite.com etc, in the text box, I would like my script to detect web addressed and add the necessary HTML tags before and after ... this is needed because unlike MIME email, HTML email must have the A HREF tags in order for the link to become hyperlinked. So here is what I need ... a code example that will detect a web address in the submitted data and add the <a href="http://www.mysite.com">www.mysite.com"</a> tags before and after the found web address. I see Perl Forum scripts do this all the time but i have no idea how it's done. If you are able to provide an example that would be wonderful. Thankx! RV Robert V |
|
|
|
|
#2 |
|
Posts: n/a
|
Robert V <> wrote in message news:45SRa.482188$. ca... > Hi all, another area I could use some help with is changing submitted data > based on the data conditions ... I will elaborate. I have a form textarea > where a user can type in some text. This text is sent to a perl script that > eventually will send that data to someone by email in HTML format. Here is > where I need some help. > > If a user was to type in a web address www.mysite.com etc, in the text box, > I would like my script to detect web addressed and add the necessary HTML > tags before and after ... this is needed because unlike MIME email, HTML > email must have the A HREF tags in order for the link to become hyperlinked. > So here is what I need ... a code example that will detect a web address in > the submitted data and add the > try something like "<a href=\"http://".$sitename.\">".$sitename,"\"</a>" thant should do it! > <a href="http://www.mysite.com">www.mysite.com"</a> > > tags before and after the found web address. I see Perl Forum scripts do > this all the time but i have no idea how it's done. If you are able to > provide an example that would be wonderful. Thankx! > > RV > > |
|