You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by mo...@dit.unitn.it on 2003/01/29 19:05:37 UTC

another

Good day, my problem is the following: I use the Eric Fesler's taglib for 
realize dynamic link in this way:


<mytag:IterS colors="#FFFFFF,#E5E9F5">
<TR bgcolor="<%=Color%>">
    <TD align=left><%=CorsoStudioId%></TD>
    <TD align=left><%=CorsoStudioName%></TD>
    <TD align=left><%=CorsoStudioFacolta%></TD>
    <TD align=left><%=CorsoStudioCrediti%></TD>
    <TD align=left>
	<hm:link page="/corsiIA.do">
	    <hm:linkparam id="IDCorsoS"  name="CorsoStudioId"/>
	    <hm:linkparam id="IDFacolta"  name="IDFacolta"/>
	        Vis. Corsi Insegn.
	</hm:link>
    </TD>
</TR>
</mytag:IterS>

where IDFacolta is an parameter that I get from the request and CorsoStudioId 
is a value that I get from my taglibrary (this iterate on a collection that i 
pass with the controller). Now I want to know if  is possible use the tag < 
html: link> of struts with a HashMap, but using an only HashMap and passing 
this between the varied jsp/ action in the request (because I want to pass 
some parameter that it haven't displayed in the url). Before i usying:

<%
	HashMap mappaold= (HashMap) request.getAttribute ( "map");
 // I recover the values from the "old" HashMap 
%>

<mytag:IterS colors="#FFFFFF,#E5E9F5">
		<TR bgcolor="<%=Color%>">
			<TD align=left><%=CorsoStudioId%></TD>
			<TD align=left><%=CorsoStudioName%></TD>
			<TD align=left><%=CorsoStudioFacolta%></TD>
			<TD align=left><%=CorsoStudioCrediti%></TD>
			<TD align=left>
		<%
			HashMap mappa = new HashMap();
        		mappa.putAll(mappaold);	
			mappa.put("IDCorsoS",CorsoStudioId);
		%>		
			<html:link action="/corsiIA.do" name="mappa" />
			</TD>
		</TR>
</mytag:IterS>

Here I use more HashMap one for any cycles (es: 100 cycles= 
100HashMap :<  ). .I'd like to know if it' s possible to use only one and if 
yes how?Or,if this are impossible, how i can pass other parameter from this 
jsp and its controller if i don't put this parameter on the link?
I thank for the help.
p.s. Sorry for my english.
Alessio.

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


Parameters

Posted by mo...@dit.unitn.it.
Good day..how i can pass other parameter from jsp and its controller if i don't 
put this parameter on the link?(see my previous mail <html:link> for more 
details)
Example i have:

<hm:link page="/corsiIA.do">
        <hm:linkparam id="IDCorsoS"  name="CorsoStudioId"/>
        <hm:linkparam id="IDFacolta"  name="IDFacolta"/>
                 Vis. Corsi Insegn.
</hm:link>

It' possible send in the request another parameter that not contained in the 
link(example other than CorsoStudioId and IDFacolta can i pass IDP...?)
I thank for the help.
p.s. Sorry for my english.
Alessio.

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


Posted by mo...@dit.unitn.it.
Good day, my problem is the following: I use the Eric Fesler's taglib for 
realize dynamic link in this way:
 
 
<mytag:IterS colors="#FFFFFF,#E5E9F5">
 <TR bgcolor="<%=Color%>">
     <TD align=left><%=CorsoStudioId%></TD>
     <TD align=left><%=CorsoStudioName%></TD>
     <TD align=left><%=CorsoStudioFacolta%></TD>
     <TD align=left><%=CorsoStudioCrediti%></TD>
     <TD align=left>
 	<hm:link page="/corsiIA.do">
 	    <hm:linkparam id="IDCorsoS"  name="CorsoStudioId"/>
 	    <hm:linkparam id="IDFacolta"  name="IDFacolta"/>
 	        Vis. Corsi Insegn.
 	</hm:link>
     </TD>
 </TR>
</mytag:IterS>
 
where IDFacolta is an parameter that I get from the request and CorsoStudioId
is a value that I get from my taglibrary (this iterate on a collection that i
pass with the controller). Now I want to know if  is possible use the tag < 
html: link> of struts with a HashMap, but using an only HashMap and passing 
this between the varied jsp/ action in the request (because I want to pass 
some parameter that it haven't displayed in the url). Before i usying:

<%
	HashMap mappaold= (HashMap) request.getAttribute ( "map");
 // I recover the values from the "old" HashMap 
%>
 
<mytag:IterS colors="#FFFFFF,#E5E9F5">
 		<TR bgcolor="<%=Color%>">
 			<TD align=left><%=CorsoStudioId%></TD>
 			<TD align=left><%=CorsoStudioName%></TD>
 			<TD align=left><%=CorsoStudioFacolta%></TD>
 			<TD align=left><%=CorsoStudioCrediti%></TD>
 			<TD align=left>
 		<%
 			HashMap mappa = new HashMap();
         		mappa.putAll(mappaold);	
 			mappa.put("IDCorsoS",CorsoStudioId);
 		%>		
 			<html:link action="/corsiIA.do" name="mappa" />
 			</TD>
 		</TR>
</mytag:IterS>
 
Here I use more HashMap one for any cycles (es: 100 cycles= 
100HashMap :<  ). .I'd like to know if it' s possible to use only one and if
yes how?Or,if this are impossible, how i can pass other parameter from this 
jsp and its controller if i don't put this parameter on the link?
I thank for the help.
p.s. Sorry for my english.
Alessio.

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