That is the question. I haven't checked the code yet but I assume the component tag does not get updated with the autolink id which is why it is not found and why a new one is generated.
Juergen On 11/19/05, Arto Arffman <[EMAIL PROTECTED]> wrote: > Never done bug reports with bugzilla but I think I can do it. > > But why links are generated in every render??? > > > 2005/11/19, Juergen Donnerstag <[EMAIL PROTECTED]>: > > > > On 11/18/05, Arto Arffman <[EMAIL PROTECTED]> wrote: > > > It might be the intention, but if it is, there is an error with this > > > solution. > > > > > > When the template is parsed each link-tag inside <wicket:link> is > assigned > > > id named "_autolink_". Later this tag is handled by AutoLinkResolver. > > > > > > AutoLinkResolver: > > > private final Component resolveAutomaticLink(final MarkupContainer > > > container, final String id, > > > final ComponentTag tag) > > > ... > > > final String autoId = id + Integer.toString(page.getAutoIndex()); > > > // By setting the component name, the tag becomes a Wicket component > > > // tag, which must have a associated Component. > > > tag.setId(autoId); > > > ... > > > > > > When this is done second time id will contain already handled id, e.g > > > _autolink_1 and a new number is appended. > > > And when there are more than 9 links inside one <wicket:link> there will > be > > > an error like: > > > The markup file must not contain the same wicket:id at the same level: > > > _autolink_11 > > > > > > I think it would be more efficient to create the link components only > once. > > > And then this problem would also be solved. This is only problem with > > > current cvs-head, I couldn't get the same exception with 1.1-final. I > don't > > > know how it was handled in that version. > > > > > > > Would you please create a bug for it in sourceforge. Thanks. > > > > It does work in 1.1 because we did not enforce the 1:1 relationship > > between component and tag, which we now more or less have to do in > > order to support AJAX. > > > > Juergen > > > > > > ------------------------------------------------------- > > This SF.Net email is sponsored by the JBoss Inc. Get Certified Today > > Register for a JBoss Training Course. Free Certification Exam > > for All Training Attendees Through End of 2005. For more info visit: > > http://ads.osdn.com/?ad_idv28&alloc_id845&opclick > > _______________________________________________ > > Wicket-user mailing list > > Wicket-user@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/wicket-user > > > > ------------------------------------------------------- This SF.Net email is sponsored by the JBoss Inc. Get Certified Today Register for a JBoss Training Course. Free Certification Exam for All Training Attendees Through End of 2005. For more info visit: http://ads.osdn.com/?ad_idv28&alloc_id845&op=click _______________________________________________ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user