What wicket version are you using?

-Matej

On Mon, Apr 7, 2008 at 2:38 PM, Daniel Stoch <[EMAIL PROTECTED]> wrote:
> Hi,
>
>  There is a strange behaviour when I'm trying refresh
>  WebMarkupContainer component using AjaxLink. I have a simple page:
>
>  public HomePage(final PageParameters parameters) {
>     final WebMarkupContainer container = new WebMarkupContainer("container");
>     add(container);
>     container.setOutputMarkupId(true);
>     add(new AjaxLink("ajaxLink") {
>
>       public void onClick(AjaxRequestTarget target) {
>         target.addComponent(container);
>       }
>
>     });
>   }
>
>
>  <html>
>     <head>
>         <title>AjaxLink test</title>
>     </head>
>     <body>
>         <p wicket:id="container">
>             <h4>Header A</h4>
>         </p>
>         <div>
>             <a wicket:id="ajaxLink">Ajax request</a>
>         </div>
>     </body>
>  </html>
>
>  For the first time page is rendered as follows:
>  Header A
>  Ajax request
>
>  When I click "Ajax request" link the onClick metod is called to
>  refresh container component (which is WebMarkupContainer).
>  But instead of refreshing (repainting) of "container" markup (<p
>  wicket:id="container">...</p> markup), it is dupliacted below the
>  original paragraph. Each click on this ajax link causes this paragraph
>  multiplication and after eg. 4 clicks the page looks like:
>  Header A
>  Header A
>  Header A
>  Header A
>  Header A
>  Ajax request
>
>  Is it a bug or I should not use WebMarkupContainer to refresh its
>  contents in ajax calls?
>
>  --
>  Daniel
>
>  ---------------------------------------------------------------------
>  To unsubscribe, e-mail: [EMAIL PROTECTED]
>  For additional commands, e-mail: [EMAIL PROTECTED]
>
>



-- 
Resizable and reorderable grid components.
http://www.inmethod.com

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

Reply via email to