RE: Struts2 with Authentication & Security

2009-08-21 Thread Zied Bejaoui
HI GUYS, Another problem is showing up before trying to login here is the stack track: SEVERE: Exception starting filter struts2 java.lang.ClassNotFoundException: org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter at org.apache.catalina.loader.WebappClassLoader.loadClas

RE: Hibernate3+Spring2.5+Struts2

2009-08-21 Thread Zied Bejaoui
example/message.jsp Thannks. -Original Message- From: Wes Wannemacher [mailto:w...@wantii.com] Sent: 20 August 2009 19:44 To: Struts Users Mailing List Subject: Re: Hibernate3+Spring2.5+Struts2 On Thu, Aug 20, 2009 at 12:38 PM

RE: Hibernate3+Spring2.5+Struts2

2009-08-20 Thread Zied Bejaoui
Thanks for the help guys. change User usr= userService.getUser(username); to User usr=userServiceImp.getUser(username); userService is a UserServiceImp instance--> UserServiceimp userService. avoid static references such as userService.getUser(username); better to getUserService().getUse

RE: Hibernate3+Spring2.5+Struts2

2009-08-20 Thread Zied Bejaoui
Hi Martin, Thanks for your help, i have de fined the hibernate template like this like this: And then use it in the DAO: I couldn’t change this line by adding the parameter cause it shows an error so kept it like this: public User getUser(String userName) { return (User)getHibernat

RE: Hibernate3+Spring2.5+Struts2

2009-08-20 Thread Zied Bejaoui
This is the definition of my session factory, hibernate properties and data source : po/user.hbm.xml hibernate.dialect=org.hibernate.dialect.MySQLDialect MY d

RE: Hibernate3+Spring2.5+Struts2

2009-08-20 Thread Zied Bejaoui
I still have the same exception, I am posting all my code amd my project structure hope you can fix me to fix the problem: Package action: package action; import com.opensymphony.xwork2.ActionSupport; import java.util.Locale; import org.springframework.context.support.ResourceBundleMessageSource

RE: Hibernate3+Spring2.5+Struts2

2009-08-19 Thread Zied Bejaoui
; :( It's really difficult for us to help when we don't know the line that's causing the error: *you* know that, and should either tell us, or provide a means for us to figure it out. The more relevant information you can provide the easier it is for us to help :) Dave Zied Bejaoui

RE: Hibernate3+Spring2.5+Struts2

2009-08-19 Thread Zied Bejaoui
error: *you* know that, and should either tell us, or provide a means for us to figure it out. The more relevant information you can provide the easier it is for us to help :) Dave Zied Bejaoui wrote: > Well the problem is that this is my first example with spring and hibernate > I have dow

RE: Hibernate3+Spring2.5+Struts2

2009-08-19 Thread Zied Bejaoui
09 at 1:59 PM, Zied Bejaoui wrote: > Thanks for your help, I have fixed this problem by removing the admin property from the mapping file, now I am having another error, the login page display then as soon as I enter the login details I receive this exception: > > java.lang.NullPointerEx

RE: Hibernate3+Spring2.5+Struts2

2009-08-19 Thread Zied Bejaoui
Thanks for your help, I have fixed this problem by removing the admin property from the mapping file, now I am having another error, the login page display then as soon as I enter the login details I receive this exception: java.lang.NullPointerException at action.LoginAction.execute(Log

RE: Hibernate3+Spring2.5+Struts2

2009-08-19 Thread Zied Bejaoui
Thanks for you reply, In my table I have three coloumns ID, UserName and password. This is my po.User: package service; import po.User; /** * * @author ABIS1 */ public class UserServiceImp implements UserService { private dao.UserDao userDao; public void addUser(String userNam