views:

82

answers:

1

I'm using the Rules module to send a mail and I'm inserting a token that represents a CCK Date field. This token contains HTML formatting which should not be present in a plain text mail.

So when I insert the token I get

<span class="date-display-single">06.09.2010 - 15:52</span>

Instead of

06.09.2010 - 15:52

which is what I want.

Any idea on how to access the Date as a token without the formatting, just plain text?

+1  A: 

The easiest thing will probably be to create your own token with the html stripped away. You should be able to copy how the date module does this into your custom module, and just edit the formatting, by using check_plain or something similar.

That way you can keep the formatting when you actually want it.

googletorp

related questions