Im developing one application here i need to pass the data from servlet to JSP .How can i pass it ? i tried by request.setAttribute() but it printing as null in JSP page . how can i solve this problem?

Recommended Answers

All 2 Replies

A bean? A session context object? an application context object? etc, etc, etc.

try this,

create some session object,
for example;
you need to send the value of variable name;
session.setAttribute("name",variable name);
and get in on jsp using;
String name=(String)session.getAttribute("name");
for same thing you can also try this:
get values on your jsp page using;
String name=request.getParameter("name");

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.