You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Alex Colic <al...@pop-ware.com> on 2001/09/28 15:36:29 UTC
How to do a mailto:
Hi,
I am having a problem with a mailto link.
I have a line of text in my page:
<bean:write name="bean" property="e-mail>
I want to change this to a link that open the clients e-mail program and
inserts the e-mail into the to: box.
I can get this to work:
<html:link href="mailto:">
<bean:write name="person" property="e-mail">
</html:link>
How do I add the e-mail address to the link?
I know that the resulting html should be: <a
href="mailto:email@somewhere.com">
Thanks for any info.
Regards
Alex
Re: How to do a mailto:
Posted by Erik Hatcher <ja...@ehatchersolutions.com>.
I'd do it this way:
<a href="mailto:<bean:write name="bean" property="e-mail">"><bean:write
name="bean" property="e-mail></a>
<html:link> is useful for adjusting context-relative http URL's, but for a
mailto: link just writing pure HTML is fine.
Erik
----- Original Message -----
From: "Alex Colic" <al...@pop-ware.com>
To: "Struts" <st...@jakarta.apache.org>
Sent: Friday, September 28, 2001 6:36 AM
Subject: How to do a mailto:
> Hi,
>
> I am having a problem with a mailto link.
>
> I have a line of text in my page:
>
> <bean:write name="bean" property="e-mail>
>
> I want to change this to a link that open the clients e-mail program and
> inserts the e-mail into the to: box.
>
> I can get this to work:
>
> <html:link href="mailto:">
> <bean:write name="person" property="e-mail">
> </html:link>
>
> How do I add the e-mail address to the link?
>
> I know that the resulting html should be: <a
> href="mailto:email@somewhere.com">
>
> Thanks for any info.
>
>
> Regards
>
> Alex
>
>