[Opensource] links in expresso

Michael Rimov rimovm at centercomp.com
Wed Jul 24 00:29:42 PDT 2002


At 11:20 AM 7/23/2002 -0600, you wrote:
>Is there a way to create links in expresso?  I'm not really interested in
>using the struts html:link tag.  I've been thinking that you should be able
>to create links from transition objects.  Has anyone done anything like
>this?

Well, there's lots of ways to do it... html:link is one of them... 
expresso:TransitionTag is another easy way to create buttons.  Another way is:

<bean:define id="url" property="yourTransition.url"/>
<bean:define id="label" property="yourTransition.label"/>

Then you can do your html anchor with the appropriate labels, etc.




>Benefits:
>1)  You could setup your query string with the .addParam() and
>.getParamString() methods.
>2)  All the transitions are controlled by your controller now

Using the results above, you get the same results unless I'm 
misunderstanding the question.

>Questions:
>Using transitions for forms you have to specify the path to the controller
>in the form action attribute (i.e. form action="/myApp/Controller.do")  How
>would you do this in a link tag?

TransitionTag will do all that automatically for you.  Take a look at it 
and let us know if it helps.

                                         -Mike




More information about the Opensource mailing list