You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by al...@t-online.de on 2005/08/06 11:47:12 UTC

Using Tiles as Email Templates

Hi all,

 

I have a tile layout that renders an email text (plain). Now after

the user selects an action(ie. password retrieval), I want to use the output

of the tile (configured as an action path) as the source for my email in the

other action (ie. password retrieval).

 

I know how to pull the output performing an HttpClient request(using the

apache commons) to get that, but is there a different way to do just that.

 

In the past I used velocity to render the emailtemplates, and that didn't

require me to use a HttpClient request.

 

any ideas ?

 

rgds

albi


RE: Using Tiles as Email Templates

Posted by al...@t-online.de.
LOL... 

After diving into tiles I too wonder myself WHY all this fuzz ... Velocity
is still the best bet for that ;)

I was concerned about the memory used to fire up additional stuff. Now I
have a central service providing the parsing functionality, keeping only one
instance.

Mind sometimes goes dizzy after long hours of thinking in circles ;)

Rgds
albi

-----Original Message-----
From: Larry Meadors 
Sent: Saturday, August 06, 2005 4:10 PM
To: Struts Users Mailing List 
Subject: Re: Using Tiles as Email Templates

On 8/6/05, aleiprecht@t-online.de <al...@t-online.de> wrote:
> I still wonder, how one would do it with the standard struts/tiles
combination.

Hmm, I wonder WHY?

Larry

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: Using Tiles as Email Templates

Posted by Larry Meadors <la...@gmail.com>.
On 8/6/05, aleiprecht@t-online.de <al...@t-online.de> wrote:
> I still wonder, how one would do it with the standard struts/tiles combination.

Hmm, I wonder WHY?

Larry

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


RE: Using Tiles as Email Templates

Posted by al...@t-online.de.
BTW:

I went back doing it with Velocity ....
but I still wonder, how one would do it with the standard struts/tiles
combination. 

Rgds
albi


-----Original Message-----
From: a@bbb.cc [a@bbb.cc] 
Sent: Saturday, August 06, 2005 11:47 AM
To: 'Struts Users Mailing List'
Subject: Using Tiles as Email Templates

Hi all,

 
I have a tile layout that renders an email text (plain). Now after
the user selects an action(ie. password retrieval), I want to use the output
of the tile (configured as an action path) as the source for my email in the
other action (ie. password retrieval).
 

I know how to pull the output performing an HttpClient request(using the
apache commons) to get that, but is there a different way to do just that.

 
In the past I used velocity to render the emailtemplates, and that didn't
require me to use a HttpClient request.

any ideas ?


rgds
albi


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


RE: Using Tiles as Email Templates

Posted by al...@t-online.de.
This is what I meant btw ;)


PWRetrievalForm
	User enters his answer to the secret

PWRetrievalAction
	checks the answer against the DB
	and pulls the data beans containing
	the information needed for the template
	pulls the email
text<----------------+---------+(pwretrieval.template)
		| 				       |<tiles:insert
def="email" |
		|				       |<tiles:put from
request   |
		|				       |lalala
|
		|				       |Emailtext with
getAsString|
		|				       |Emailtext with
getAsString|
		|				       |Emailtext with
getAsString|
		|
+--------------------------+
           \_/
	sends the email
		| 
		|	
		|	
		|	
		|	
		|	
		|	
	     \_/
	forward to the page configured in the PWRetrievalAction
	and outputs to the user (we've sent....)



-----Original Message-----
From: aleiprecht@t-online.de [mailto:aleiprecht@t-online.de] 
Sent: Saturday, August 06, 2005 11:47 AM
To: 'Struts Users Mailing List'
Subject: Using Tiles as Email Templates

Hi all,

I have a tile layout that renders an email text (plain). Now after
the user selects an action(ie. password retrieval), I want to use the output
of the tile (configured as an action path) as the source for my email in the
other action (ie. password retrieval).

I know how to pull the output performing an HttpClient request(using the
apache commons) to get that, but is there a different way to do just that.

In the past I used velocity to render the emailtemplates, and that didn't
require me to use a HttpClient request.

any ideas ?

rgds

albi



---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org