Hi all,
the following code works. Just out of interest: how would I make the code
more elegant? e.g. squeez all the s/// into one?
$_ = "somebody";
$h{$_} = "name
adress
phone
mailto:[EMAIL PROTECTED]"
and the variable
$htmlize = $h{$_};
$htmlize =~ s/\n/<BR>\n/g;
$htmlize =~ s/\@/\\@/;
$htmlize =~ s/(mailto:)(.+)(<BR>\n)/\<a
href=\"$1$2\?subject=request to $_\">Email to $_\<\/a>$3/g;
my result looks like this:
name<BR>
adress<BR>
phone<BR>
<a href="mailto:my.name\@mailing.org?subject=request to somebody">Email to
somebody</a><BR>
is there a more elegant way for the s/// commands?
$htmlize = $h{$_};
$htmlize =~ s/\n/<BR>\n/g;
$htmlize =~ s/\@/\\@/;
$htmlize =~ s/(mailto:)(.+)(<BR>\n)/\<a
href=\"$1$2\?subject=Anfrage zu $_\">Email to $_\<\/a>$3/g;
greetings,
Stefan
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]