Swastik
Swastik
Swastik Dey wrote:You are confusing yourself.
Step1 . User registers you have a servlet that saves the record in users table and send a confirmation mail to the user with a login link (So this mail will have just the login link no need for any tokenid)
Step2 User clicks on forget password. You show a html/jsp page to take the email id as input. This goes to a servlet where you create the resetlink with tokenid and send the mail and save the record in the other table where you have tokenid field.
Step3 User clicks on the link sent to him/her in the email. The request comes to another servlet where you retrieve the tokenid and do necessary validation and perform desired task.
Gayathri Gayu wrote:[ But how will i retrieve the tokenid?
Swastik
Swastik
this one?step 3. I should keep another java file to retrieve the tokenid and display the reset password.jsp page. Am i correct.
Swastik
Swastik
Swastik
Swastik
Swastik
Swastik
java.sql.SQLException: No value specified for parameter 2gayathri13990@gmail.com
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1055)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:956)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:926)
at com.mysql.jdbc.PreparedStatement.fillSendPacket(PreparedStatement.java:2176)
at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1993)
at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1937)
at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1922)
at com.gayathri.SendMail.send(SendMail.java:66)
at com.mvc.controller.RegisterServlet.processResetpasswordRequest(RegisterServlet.java:122)
at com.mvc.controller.RegisterServlet.doPost(RegisterServlet.java:42)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:660)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:493)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81)
at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:660)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:798)
at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:808)
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1498)
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
at java.lang.Thread.run(Thread.java:748)
Paul Clapham wrote:Well, yeah.
You specified a value for parameter 1 twice and didn't specify a value for parameter 2.
Swastik
Swastik
Swastik
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime. |