Services | Updates | Contact
Home | Ajax | BioInformatics | Dojo | EAI | EJB | Hibernate | J2ME | Java | Java Glossary | Java Servlets | JavaScript | Jboss | JDBC | JDO | Jmeter | JSF | JSP | JUnit | Maven | MySQL | Spring Framework | SQL | Struts | Technology | WAP | Web Services | XML

Adding DOCTYPE to a XML File
In this section, you will learn to add a DOCTYPE to your XML file using the DOM APIs.
 
Facelet repeat Tag
Facelet repeat Tag is used to iterate over the list of items. The name of list of items is specified by the EL expressio
 
More Tutorials...

Search All Tutorial
Top Search: Loan Struts Open Source

Programming Tutorials: Ajax | Articles | JSP | Bioinformatics | Database | Free Books | Hibernate | J2EE | J2ME | Java | JavaScript | JDBC | JMS | Linux | MS Technology | PHP | RMI | Web-Services | Servlets | Struts | UML

 
 
Struts

 
Comments
 
 

 

Login and User Registration Application

                         

In this tutorial we will learn how to develop login application based on Struts, Hibernate and Spring Framework. We will be using MySQL database to store the user information, and then authenticate the user at the login time. You can easily use this Login application to quick start your application development.

  1. Simplified Application Development
    This tutorial provides an outlook of the alternative lightweight approaches for building J2EE enterprise based web application by combining all the three mentioned frameworks e.g. Struts, Hibernate and Spring.
       
  2. About this Login Application
    This tutorial provides some simple steps for creating a website login application that can be used later in any big Struts Hibernate and Spring based application.
    => Login Form
    Login Screen our web application allows the user the registered user to logon to the system.
    => Update Profile
    The Update Profile page allows the logged in user to update his/her profile. Form allows user to change his/her password.
    => Forgot Password
    The Forgot Password for allows the retrieve their forgotten password.
      
  3. Designing and creating database
    Database designing is considered as crucial stage in the development lifecycle of the web application. The database is finally responsible for storing the data in the database for retrieval in future.
         
  4. Downloading the required software and integration into web application
    In this section you will learn how to download required software for our Login and Registration Application. In this tutorial we are using one of the best technologies (Struts, Hibernate and Spring).
      
  5. Writing POJO and configuration files
    We have only one table into the database and we need one POJO class and the hibernate mapping file to map the login object to the database table.
      
  6. Writing Spring Application Context definition xml
    In this section we will wire up the components by defining the Application context definition file (applicationContext-hibernate.xml). This file is used by context loader servlet to initialize the Spring application context.
      
  7. Configuring the Spring Context Loader Servlet
    In this section we will learn about Spring's Context loader servlet and then see how to add the required configuration in the web.xml file to load the Spring Context.
      
  8. Understanding Spring Struts Hibernate DAO Layer
    In this section we will understand how Spring Hibernate and Struts will work together to provide best solution for any web based application.
      
  9. DAO Layer explained
    In this section we will explain you the DAO Layer of our application.
      
  10. Send Mail Bean
    In our application we have developed mailer bean that sends welcome email when a new user is registered to the system. Mail Bean also used when user asks for the forgotten password.
      
  11. Developing User Registration Form
    In this section we will develop user registration form code.
      
  12. User Registration Action Class and DAO code
    In this section we will explain how to write code for action class and code for saving data into database.
      
  13. Login Form
    In this section we will develop Login Form code for our application.
      
  14. Developing Login Action Class
    In this section we will explain how to write code for login action class and database code for validating the user against database.
      
  15. Developing Forgot Password Form
    In this section we will develop Forgot Password Form code for our application.
      
  16. Developing Forgot Password Action Class
    In this section we will explain how to write code for Forgot Password and code for emailing the password.
      
  17. Update Profile form and action class
    In this section we will learn about update profile logic.
      
  18. Compiling and testing the application
    In this application we will compile and deploy the application on tomcat.
      
  19. Download Full Source Code
    You can download the full source code of the application from here.

                         

Facing Programming Problem?
Add This Tutorial To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 

Current Comments

4 comments so far (post your own) View All Comments Latest 10 Comments:

can u help me to send the j2ee coding for online examination test and displaying the total score marks

Posted by Anu on Monday, 11.5.07 @ 19:24pm | #35633

Hey BayyannaGoud,
Have u got the idea of how to create getter and setter methods without using ActionForm?? I want to implement the code in ActionClass itself.

Posted by irreversible1983 on Thursday, 10.18.07 @ 14:40pm | #34326

hai
i tried to deploy the file
but we get in jboss these Exceptions



11:58:14,373 INFO [EARDeployer] Init J2EE application: file:/D:/jboss-4.0.5.GA/
server/default/deploy/project.ear
11:58:14,842 ERROR [MainDeployer] Could not initialise deployment: file:/D:/jbos
s-4.0.5.GA/server/default/deploy/project.ear
org.jboss.deployment.DeploymentException: No META-INF/application.xml found
at org.jboss.deployment.EARDeployer.init(EARDeployer.java:133)
at org.jboss.deployment.MainDeployer.init(MainDeployer.java:872)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:809)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:782)
at sun.reflect.GeneratedMethodAccessor55.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatch
er.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractIntercept
or.java:133)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelM
BeanOperationInterceptor.java:142)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
at $Proxy8.deploy(Unknown Source)
at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymen
tScanner.java:421)
at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentS
canner.java:634)
at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.
doScan(AbstractDeploymentScanner.java:263)
at org.jboss.deployment.scanner.AbstractDeploymentScanner.startService(A
bstractDeploymentScanner.java:336)
at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanS
upport.java:289)
at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMB
eanSupport.java:245)
at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatch
er.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceControl
ler.java:978)
at $Proxy0.start(Unknown Source)
at org.jboss.system.ServiceController.start(ServiceController.java:417)
at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatch
er.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
at $Proxy4.start(Unknown Source)
at org.jboss.deployment.SARDeployer.start(SARDeployer.java:302)
at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1025)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:819)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:782)
at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:766)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatch
er.java:155)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractIntercept
or.java:133)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelM
BeanOperationInterceptor.java:142)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
java:264)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
at $Proxy5.deploy(Unknown Source)
at org.jboss.system.server.ServerImpl.doStart(ServerImpl.java:482)
at org.jboss.system.server.ServerImpl.start(ServerImpl.java:362)
at org.jboss.Main.boot(Main.java:200)
at org.jboss.Main$1.run(Main.java:490)
at java.lang.Thread.run(Thread.java:619)
11:58:14,967 ERROR [URLDeploymentScanner] Incomplete Deployment listing:

--- Incompletely deployed packages ---
org.jboss.deployment.DeploymentInfo@1120aaea { url=file:/D:/jboss-4.0.5.GA/serve
r/default/deploy/project.ear }
deployer: org.jboss.deployment.EARDeployer@8e4805
status: null
state: FAILED
watch: file:/D:/jboss-4.0.5.GA/server/default/deploy/project.ear
altDD: null
lastDeployed: 1187245694842
lastModified: 1187245694373
mbeans:


11:58:15,076 INFO [Http11BaseProtocol] Starting Coyote HTTP/1.1 on http-0.0.0.0
-8080
11:58:15,154 INFO [ChannelSocket] JK: ajp13 listening on /0.0.0.0:8009
11:58:15,170 INFO [JkMain] Jk running ID=0 time=0/32 config=null
11:58:15,185 INFO [Server] JBoss (MX MicroKernel) [4.0.5.GA (build: CVSTag=Bran
ch_4_0 date=200610162339)] Started in 23s:931ms

please help in deployment
thank u

Posted by Raghavendra Kumar B on Thursday, 08.16.07 @ 11:58am | #23494

Dear all,
I heard that without using the actionForm still we cal also create the setter and getter method. Is that true? if so how?
I would like to implement the code in ActionClass only without to touch the ActionForm

Posted by BayyannaGOud on Thursday, 07.26.07 @ 13:11pm | #21977

Leave your comment:

Name:

Email:

URL:

Title:

Comments:


Enter Code:

 

Note: Emails will not be visible or used in any way, and are not required. Please keep comments relevant. Any content deemed inappropriate or offensive may be edited and/or deleted.

No HTML code is allowed. Line breaks will be converted automatically. URLs will be auto-linked. Please use BBCode to format your text.

  EAI Articles
  Java Certification
Tell A Friend
Your Friend Name
Search Tutorials

 

 
 
Browse all Java Tutorials
Java JSP Struts Servlets Hibernate XML
Ajax JDBC EJB MySQL JavaScript JSF
Maven2 Tutorial JEE5 Tutorial Java Threading Tutorial Photoshop Tutorials Linux Technology
Technology Revolutions Eclipse Spring Tutorial Bioinformatics Tutorials Tools SQL
 

Home | JSP | EJB | JDBC | Java Servlets | WAP  | Free JSP Hosting  | Search Engine | News Archive | Jboss 3.0 tutorial | Free Linux CD's | Forum | Blogs

About Us | Advertising On RoseIndia.net  | Site Map

India News

Send your comments, Suggestions or Queries regarding this site at roseindia_net@yahoo.com.

Copyright © 2007. All rights reserved.