I have a form that ask for user to enter ID. This form is send to a servlet which checks database to see if user exist. If the user exists then it sends me back their ordere
you should set scope of your UserFound.jsp to request.
ArrayList orderList = (ArrayList ) request.getAttribute("theOrder");
<% If(orderList != null) {%>
<% for(String orderName : orderList ) { %>
- <%= orderName %>
<% } %>
<% }else{ %>
No Order Found
<% } %>
OR
ArrayList orderList = (ArrayList ) request.getAttribute("theOrder");
<% If(orderList != null) {%>
<% for(int orderNum =0;i< orderList.size();++orderNum ) { %>
- <%= orderList.get(orderNum )%>
<% } %>
<% }else{ %>
No Order Found
<% } %>