[ZPT] replacing href attribute to get an email-link

Andreas Jung Andreas Jung <lists@andreas-jung.com>
Sat, 08 Mar 2003 18:54:39 +0100


--On Samstag, 8. M=E4rz 2003 18:43 +0100 Erik Mueller <erikmueller@gmx.de>=20
wrote:

> Hi,
>
> I am a newbie to Zope and ZPT, and this maybe a newbie question. I hope
> you nevertheless answer it and help me.
>
> I now that the keyword "attributes" is replacing attribute elements. But =
I
> want to replace the href attribute so that it looks like this <a
> href=3D"mailto:xyz@xyz.com">. I use tal:attributes=3D"href here/email", =
but
> how do I insert the "mailtto:" additionally?
>

A look a ZPT reference would have solved the problem:

tal:attributes=3D"href string:mailto:${here/email}"

or
tal:attributes=3D"href python: 'mailto:' + here.email"

-aj