I didn't think about that. However, I changed the spans to divs and still the same result. :-(
I put a new build out at the same urls. Johan Compagner wrote: > > can a span have other block elements? > try to make the span a div > > johan > > > On 5/23/07, Flavius <[EMAIL PROTECTED]> wrote: >> >> >> The fragment contents appear fine. >> When I change the value on the dropdown, I expect the >> AjaxFormComponentUpdatingBehavior.onUpdate() to set >> the visibility to false. >> >> >> My dropdown has this added: >> >> dropDown.add(new >> AjaxFormComponentUpdatingBehavior("onchange") >> { >> protected void onUpdate(AjaxRequestTarget >> target) >> { >> target.addComponent(container); >> text2Fragment.setVisible(false); >> } >> }); >> >> Now if I substitute a TextField instead of a fragment (or panel), it >> correctly >> sets the visibility to false. But with the fragment, it stays visible >> when >> the >> onchange event fires. >> >> I put up a couple of test pages, if you want to see: >> http://24.248.103.44/pages/Test (this is just the component, which works) >> http://24.248.103.44/pages/Test2 (this is with the fragment, which does >> not) >> >> I included the java source on each page. >> >> >> Johan Compagner wrote: >> > >> > so whats in the fragment doesnt disappear? looking at the ajax code we >> > see an empty component comming up. I guess the ajax console is saying >> > exatly the same stuff when you do it for the textfield? >> > >> > On 5/23/07, Flavius <[EMAIL PROTECTED]> wrote: >> >> >> >> >> >> There are no errors. I did try setting the outputMarkupId to >> >> true for the fragment. In the examples (and in my own code >> >> with just the TextField), setting the container was sufficient. >> >> Adding this to the Fragment had no effect. >> >> >> >> Here is the Ajax output from the console: >> >> >> >> INFO: >> >> INFO: Initiating Ajax POST request on >> >> >> /;jsessionid=32444A7415B3D15E1792F255AFB8C5BE?wicket:interface=:0:inputForm:dropDown:-1:IUnversionedBehaviorListener&wicket:behaviorId=0&wicket:ignoreIfNotActive=true&random= >> 0.8983050159419032 >> >> INFO: Invoking pre-call handler(s)... >> >> INFO: Received ajax response (181 characters) >> >> INFO: >> >> <?xml version="1.0" encoding="UTF-8"?><ajax-response><component >> >> id="inputForm_container" ><![CDATA[ >> >> >> >> ]]></component></ajax-response> >> >> INFO: Response parsed. Now invoking steps... >> >> INFO: Response processed successfully. >> >> INFO: Invoking post-call handler(s)... >> >> >> >> Like I mentioned, if I just add a TextField (or any other form >> component) >> >> it works great. But my pages need to remove the control >> >> and label. In a couple of places, it needs to remove several >> controls, >> >> a prime candidate for a fragment or panel, imho. >> >> >> >> I've read other threads discussing setting the visibility like this: >> >> >> http://www.nabble.com/Changing-visibility-via-ajax-tf1974532.html#a5418508 >> >> >> >> So I must conclude I'm doing something wrong. >> >> >> >> >> >> >> >> >> >> Timo Rantalaiho wrote: >> >> > >> >> > On Tue, 22 May 2007, Flavius wrote: >> >> >> I am trying to setVisible on a Fragment using the >> >> >> AjaxFormComponentUpdatingBehavior object. >> >> >> It doesn't seem to work. I've also tried this with a Panel and >> that's >> >> >> not >> >> >> working either. >> >> > >> >> > How does it not work? What does the Ajax debug console say? >> >> > What is the error message / stack trace, if any? >> >> > >> >> > Looking quickly it occurs to me that maybe you should set >> >> > outputMarkupId(true) to the Fragment. If this is the case, >> >> > it should be obvious from the error message on Ajax debug >> >> > console. >> >> > >> >> > - Timo >> >> > >> >> > -- >> >> > Timo Rantalaiho +358-45-6709709 >> >> > Reaktor Innovations Oy <URL: http://www.ri.fi/ > >> >> > >> >> > >> >> >> ------------------------------------------------------------------------- >> >> > This SF.net email is sponsored by DB2 Express >> >> > Download DB2 Express C - the FREE version of DB2 express and take >> >> > control of your XML. No limits. Just data. Click to get it now. >> >> > http://sourceforge.net/powerbar/db2/ >> >> > _______________________________________________ >> >> > Wicket-user mailing list >> >> > Wicket-user@lists.sourceforge.net >> >> > https://lists.sourceforge.net/lists/listinfo/wicket-user >> >> > >> >> > >> >> >> >> -- >> >> View this message in context: >> >> >> http://www.nabble.com/setVisible-on-Fragment-with-AjaxFormComponentUpdatingBehavior-tf3800038.html#a10764129 >> >> Sent from the Wicket - User mailing list archive at Nabble.com. >> >> >> >> >> >> >> ------------------------------------------------------------------------- >> >> This SF.net email is sponsored by DB2 Express >> >> Download DB2 Express C - the FREE version of DB2 express and take >> >> control of your XML. No limits. Just data. Click to get it now. >> >> http://sourceforge.net/powerbar/db2/ >> >> _______________________________________________ >> >> Wicket-user mailing list >> >> Wicket-user@lists.sourceforge.net >> >> https://lists.sourceforge.net/lists/listinfo/wicket-user >> >> >> > >> > >> ------------------------------------------------------------------------- >> > This SF.net email is sponsored by DB2 Express >> > Download DB2 Express C - the FREE version of DB2 express and take >> > control of your XML. No limits. Just data. Click to get it now. >> > http://sourceforge.net/powerbar/db2/ >> > _______________________________________________ >> > Wicket-user mailing list >> > Wicket-user@lists.sourceforge.net >> > https://lists.sourceforge.net/lists/listinfo/wicket-user >> > >> > >> >> -- >> View this message in context: >> http://www.nabble.com/setVisible-on-Fragment-with-AjaxFormComponentUpdatingBehavior-tf3800038.html#a10770644 >> Sent from the Wicket - User mailing list archive at Nabble.com. >> >> >> ------------------------------------------------------------------------- >> This SF.net email is sponsored by DB2 Express >> Download DB2 Express C - the FREE version of DB2 express and take >> control of your XML. No limits. Just data. Click to get it now. >> http://sourceforge.net/powerbar/db2/ >> _______________________________________________ >> Wicket-user mailing list >> Wicket-user@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/wicket-user >> > > ------------------------------------------------------------------------- > This SF.net email is sponsored by DB2 Express > Download DB2 Express C - the FREE version of DB2 express and take > control of your XML. No limits. Just data. Click to get it now. > http://sourceforge.net/powerbar/db2/ > _______________________________________________ > Wicket-user mailing list > Wicket-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wicket-user > > -- View this message in context: http://www.nabble.com/setVisible-on-Fragment-with-AjaxFormComponentUpdatingBehavior-tf3800038.html#a10776667 Sent from the Wicket - User mailing list archive at Nabble.com. ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user