From: Marc G. <mgu...@ya...> - 2005-08-11 12:55:30
|
Kevin Menard wrote: > On Aug 9, 2005, at 3:09 AM, Marc Guillemot wrote: > >> Quite strange. Can you log the currently opened windows using >> WebClient.getWebWindows()? Can you check if the page is really the one >> that is currently loaded in the window: nextPage == >> nextPage.getEnclosingWindow().getEnclosedPage() > > > I'll give this a shot, but in the meanwhile, I noticed something odd. > If I set a breakpoint in the webapp to handle the form submit, it turns > out it never gets hit. So, I think HtmlUnit is just not executing the > onclick handler correctly. The rendered HTML for this checkbox is the > following: > > <input type="checkbox" name="sameShippingInfo" id="sameShippingInfo" > onchange="javascript:this.form.submit();"/> > > I've worked around this in the interim by simply calling form.submit() > and setting a couple of others things up to simulate the clicking of the > checkbox. Calling form.submit() will submit the form and redirect to > the correct page. > > Any further thoughts on this? have you tried onchange="this.form.submit();" Marc. |