You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by dinesh707 <di...@gmail.com> on 2012/10/19 09:08:35 UTC
How to clear all data in a page when you move to a new one ?
(Logout)
Hi i have two pages. "Login" page and "Main" page. so if i do the following
steps
1.) Login (Login page --> Main page)
2.) Do stuff in main page. This will re-arrange some lists
3.) Logout (Main page --> Login page)
4.) REPEAT 1.)
when i do the step 4, it will show me the "Main page" from the place i left.
I need to load a new page as i Login for the first time. How to make this
happen. Thank you
--
View this message in context: http://tapestry.1045711.n5.nabble.com/How-to-clear-all-data-in-a-page-when-you-move-to-a-new-one-Logout-tp5717050.html
Sent from the Tapestry - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: How to clear all data in a page when you move to a new one ?
(Logout)
Posted by Thiago H de Paula Figueiredo <th...@gmail.com>.
Your e-mail is confusing: the subject asks something, then the message
itself asks something else.
To clear all persisted data in a page:
@Inject private ComponentResources resources;
resources.discardPersistentFieldChanges();
To kill the user session:
@Inject
private Request request;
Session session = request.getSession(false);
if (session != null) {
session.invalidate();
}
To redirect to another page in an event handler method (includin
onActivate()): make the method return OtherPage.class or an instance of
OtherPage obtained by @InjectPage.
On Fri, 19 Oct 2012 04:08:35 -0300, dinesh707 <di...@gmail.com> wrote:
> Hi i have two pages. "Login" page and "Main" page. so if i do the
> following
> steps
> 1.) Login (Login page --> Main page)
> 2.) Do stuff in main page. This will re-arrange some lists
> 3.) Logout (Main page --> Login page)
> 4.) REPEAT 1.)
>
> when i do the step 4, it will show me the "Main page" from the place i
> left.
> I need to load a new page as i Login for the first time. How to make this
> happen. Thank you
>
>
>
>
> --
> View this message in context:
> http://tapestry.1045711.n5.nabble.com/How-to-clear-all-data-in-a-page-when-you-move-to-a-new-one-Logout-tp5717050.html
> Sent from the Tapestry - User mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
--
Thiago H. de Paula Figueiredo
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org
Re: How to clear all data in a page when you move to a new one ?
(Logout)
Posted by ael <al...@dash.com.ph>.
When logout why not redirect it to login page?
--
View this message in context: http://tapestry.1045711.n5.nabble.com/How-to-clear-all-data-in-a-page-when-you-move-to-a-new-one-Logout-tp5717050p5717051.html
Sent from the Tapestry - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org