GeeCON Prague 2014*
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes EL question Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "EL question" Watch "EL question" New topic
Author

EL question

Steven Colley
Ranch Hand

Joined: Feb 18, 2005
Posts: 290
According to the following URL:

http://localhost:8080/example/page.jsp=A=1&A=2

Parameter A has values:

<%
for (int i=0 ; i < request.getParameterValues("A").lenght ; i++ ) {
${paramValues.A[i]},
}
%>


SCJP | SCWCD | SCBCD | SCWSD 5 | SCEA (I) 1.4 | SCEA 5 | IBM SOA 669
Marc Peabody
pie sneak
Sheriff

Joined: Feb 05, 2003
Posts: 4727

Is that a typo in the URL?


A good workman is known by his tools.
Mahendar Reddy
Ranch Hand

Joined: Sep 27, 2005
Posts: 73
Hi felipe...
The code will raise translation error, as scriptlet should not contain EL.


SCJP- 98%<br />SCWCD-92%
Steven Colley
Ranch Hand

Joined: Feb 18, 2005
Posts: 290
sorry, that wasn�t what i wanted

again

<% for (int i=0 ; i < request.getParameterValues("A").lenght ; i++ ) { %>

<core ut value="${paramValues.A[i]}," />

<%}%>

and yes, that was a typo.

http://localhost:8080/example/page.jsp?A=1&A=2

tks.
 
GeeCON Prague 2014
 
subject: EL question