Hello,

can somebody help with this?

Thanx && cheers,
Martin


On Mon, 2009-04-13 at 12:16 +0200, martin.grot...@javakaffee.de wrote:
> Hi,
> 
> I'm currently evaluating how it's possible to have stateless pages with
> some information loaded asynchronously via AJAX.
> 
> I found these postings that are somehow related to this
> http://www.nabble.com/Stateless-AJAX-links-td20031309.html
> http://www.nabble.com/Directions-for-Stateless-Ajax-td17518987.html
> 
> but I'm not sure what exactly has to be done to achieve what I want.
> 
> Basically I have a simple page where I added an AjaxBehavior to a label
> that shall get replaced via AJAX:
> 
> final Label label = new Label( "info", "foo" );
> add( label.setOutputMarkupId( true ) );
> label.add(new AbstractDefaultAjaxBehavior() {
>     
>     @Override
>     protected void respond( AjaxRequestTarget target ) {
>         final Label lazyLabel = new Label( "info", "loaded asynchronously" );
>         Index.this.replace( lazyLabel.setOutputMarkupId( true ) );
>         target.addComponent( lazyLabel );
>     }
>     
>     @Override
>     public void renderHead( IHeaderResponse response ) {
>         super.renderHead( response );
>         response.renderOnDomReadyJavascript( getCallbackScript().toString() );
>     }
>     
> } );
> 
> This turns the previously statelesss page to stateful, AFAICS because of
>   getStatelessHint( Component component )
> returning false for the label.
> 
> When I change this to return true, wicket says the page is expired on the 
> AJAX request...
> 
> Can anybody say what had to be done?
> 
> Btw: I'm using wicket-1.4-SNAPSHOT.
> 
> Thanx in advance,
> cheers,
> Martin
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
> 

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to