Abhinav Kansal

Greenhorn
+ Follow
since Jun 25, 2010
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
1
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Abhinav Kansal


SessionId is an identifier for the server to identify the incoming request. You can get to know sessionid most of the time either by looking at the browser cookies or in the Url however that doesn't mean you can control that session. There can be alot of other security features associated with the session, one of them being the authenticated user. A lot of times, server issues a unique token which is encrypted in the header to identify the valid user (just an example).

Key here is that session id can only be used by server to retrieve the Httpsession object using session id. Think of a map maintained by a server and whenever any request comes and passes all the security parameter, server uses the session id and retrieve the session object from the map and serves the request.

You can refer to Head First Servlets and JSP to start with. I found it really helpful to understand the basics.
11 years ago
It's a three tiered architecture where Database layer is represent by DAO and it's Implementation is done by DaoImplement. Next is the business logic which is implemented by Service and ServiceImplemet and top is the frontend layer which is supported by Servlet and ListVO. It's a classic architecture which is implemented in most of the java/jsp web projects.

Did you ran the query independently and saw the results? However the code looks alright.

I'm not sure why you have used two different methods for the same logic. I would suggest to modularize these methods and try running the core logic within a single method. To me, it just seems to be a problem with too much code duplication rather than some technical issue.

One reason for doPost of LoginServlet.java is not getting called is that Original Servet is calling doGet in doPost. So even if your method is POST in HTML, you will still receive a call in doGet. I assume the form action URL is mapped to the originalFramework and not to the LoginServlet in you web.xml.

Reason for getting null param values can only be explained depending on how you have mapped your servlets.

One thing which you can try is calling super.doGet and super.doPost in Loginservlet.

11 years ago
Everything else is correct apart from the fact that values are being set in Java and HTML must have been placed in some JSP. To get that value, you would need to set that value in Request scope and use a $ to retrieve it on frontend.
11 years ago