You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Anthony Fox <an...@gmail.com> on 2005/06/07 16:32:54 UTC

Multiple instances of the same page for a single user session

Hi,

Is it possible to have multiple instances of the same page for a
single user session?  I have an application that searches a database
and creates a new window with the results of a search.  Users can then
go back to the original window and perform another search.  The second
search will pop up in a new window with the results of the second
search.  The two search results windows are separate searches that can
be paged and manipulated in other ways by the user.  However, they
have the same implementation.  The search form uses
IRequestCycle.getPage() to pass on search information to these results
pages.  Pooling prevents multiple instances of the same page to be
created.  Is there a way to force creation of a new instance of the
page?  Is there a better solution for doing this type of thing?

Thanks,
Anthony

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: Multiple instances of the same page for a single user session

Posted by Anthony Fox <an...@gmail.com>.
Hi,

Thanks for the response.  My results page uses a contrib:Table to page
through the search's result set.  Is it possible to set a hidden field
or a persistent parameter passed on each request for contrib:Table?

Thanks,
Anthony

On 6/7/05, Robert Zeigler <ro...@scazdl.org> wrote:
> My suggestion (and others probably have better suggestions :) is to
> ditch persistent properties for the popup page, which it sounds like you
> are using.  Instead, try putting things within the context of a form,
> and using a hidden at the beginning of the page to store the object
> information you need to restore the necessary state for that page.
> Since every page that pops up will have a unique hidden object, it
> should be fine.
> For instance, if you wanted to keep the results in the session, you
> could store them in a map, and store the key to the particular results
> in the hidden object. Then you can restore the correct result set from
> the map using the key.
> 
> Robert
> 
> Anthony Fox wrote:
> > Hi,
> >
> > Is it possible to have multiple instances of the same page for a
> > single user session?  I have an application that searches a database
> > and creates a new window with the results of a search.  Users can then
> > go back to the original window and perform another search.  The second
> > search will pop up in a new window with the results of the second
> > search.  The two search results windows are separate searches that can
> > be paged and manipulated in other ways by the user.  However, they
> > have the same implementation.  The search form uses
> > IRequestCycle.getPage() to pass on search information to these results
> > pages.  Pooling prevents multiple instances of the same page to be
> > created.  Is there a way to force creation of a new instance of the
> > page?  Is there a better solution for doing this type of thing?
> >
> > Thanks,
> > Anthony
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: Multiple instances of the same page for a single user session

Posted by Robert Zeigler <ro...@scazdl.org>.
My suggestion (and others probably have better suggestions :) is to
ditch persistent properties for the popup page, which it sounds like you
are using.  Instead, try putting things within the context of a form,
and using a hidden at the beginning of the page to store the object
information you need to restore the necessary state for that page.
Since every page that pops up will have a unique hidden object, it
should be fine.
For instance, if you wanted to keep the results in the session, you
could store them in a map, and store the key to the particular results
in the hidden object. Then you can restore the correct result set from
the map using the key.

Robert

Anthony Fox wrote:
> Hi,
> 
> Is it possible to have multiple instances of the same page for a
> single user session?  I have an application that searches a database
> and creates a new window with the results of a search.  Users can then
> go back to the original window and perform another search.  The second
> search will pop up in a new window with the results of the second
> search.  The two search results windows are separate searches that can
> be paged and manipulated in other ways by the user.  However, they
> have the same implementation.  The search form uses
> IRequestCycle.getPage() to pass on search information to these results
> pages.  Pooling prevents multiple instances of the same page to be
> created.  Is there a way to force creation of a new instance of the
> page?  Is there a better solution for doing this type of thing?
> 
> Thanks,
> Anthony
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org