c:url is a standard tag from JSTL, so I think it's better to follow standards Maybe html:link will be deprecated in a near future.
> -----Mensaje original----- > De: Jiri Chaloupka [mailto:[EMAIL PROTECTED] > Enviado el: domingo, 31 de agosto de 2003 18:36 > Para: Struts Users Mailing List > Asunto: Re: dinamically add href into html:link > > > Thanks, I used html-el and it works. > what is the better to use, use c:url or html-el:link? Or it is > equivalent here? > > And one more queestion: > I have object with application persistency (over all > sessions), and for > session I call some method to set some parameter and get > another object > (array list) and maybe store it in session. > > Now I do: > <jsp:useBean id="a" class="cz.chalu.modules.blabla.Class" > scope="application" /> > and, now provisory, this as scriptlet: > <% > a.setRequest(request); > User user = (User)session.getAttribute("user"); > if(user != null){ > a.setUser(user); > } > getServletContext().setAttribute("b", > a.getSomething().toArray()); %> next, I call some <c:forEach > ...> cykle for "b" object. > > How I can do it correctly in struts / jstl? > > Thanks, Jiri > > Mark Lowe wrote: > > > > > The ideal way would be something like this. > > > > <c:url url="${menuItem.link}"> > > <c:out var="${menuItem.name}"/> > > </c:url> > > > > Cheers Mark > > > > On Sunday, August 31, 2003, at 04:27 PM, Yann Cébron wrote: > > > >>> how I can do something as this: > >>> > >>> <html:link action="${menuItem.link}" ><c:out > >>> value="${menuItem.name}" /> > >>> ? > >> > >> > >> Use the EL-tags (look in the contrib/struts-el directory of the > >> Struts 1.1 > >> distribution), e.g. > >> > >> <html-el:link action="${menuItem.link}"> .. .. </html-el:link> > >> > >> HTH, > >> Yann > >> > >> > >> > >> > >> > --------------------------------------------------------------------- > >> To unsubscribe, e-mail: [EMAIL PROTECTED] > >> For additional commands, e-mail: > [EMAIL PROTECTED] > >> > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]