Hello there! I've a couple of questions about this topic:

I have a login page, that after the user is logged I'd like to have
the user object available for the rest of the application (aka it's
stored on the session) a persistent property exists only for a given
page right? Well I tried the global then. My login method looks like
this:

public void authenticate(IRequestCycle cycle) {
                User user = new User();
                user.setLogin(getUsername());
                user.setPassword(getPassword());
                boolean authenticate = getUserService().authenticate(user);
                if(authenticate){
                        Map global = (Map)getGlobal();
                        global.put("user",user);
                        cycle.activate("Start");
                }
                cycle.activate("Home");
                
        }

So I go to the Start page. In my page template I'd like to have
something like this:
<span jwcid="@Insert" value="ognl:user.login"> </span>
And my start.page:
<page-specification class="net.sf.webfeeds.view.start.StartPage">
        <property-specification name="user"
type="net.sf.webfeeds.model.persistence.user.User"/>
</page-specification>
My StartPage.java
public abstract class StartPage extends BasePage {
        public User getUser(){
                return (User)((Map)getGlobal()).get("user");
        }
}
I`m getting a an error, as getUser is non abstract. Ok. Whats the
procedure here? Set it as abstract and on the method pageBeginRender
set its value?

Thanks a lot

Vinicius

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to