From: Ahmed A. <asa...@ya...> - 2016-05-26 08:23:43
|
Hi Laura, Please post your complete Java code (hopefully minimal). Otherwise, you can debug HtmlUnit to see how it works. Ahmed From: nonSonoPaola <non...@gm...> To: htm...@li... Sent: Thursday, May 26, 2016 9:53 AM Subject: [Htmlunit-user] NaN values in htmlUnit getPage 'm trying to get a page html using htmlUnit library. I think some javascript are not executed properly, since I get Nan in some attribute values. I use this code for retrieving the page: webClient = new WebClient(); final HtmlPage page = webClient.getPage(TEST_WEB_PAGE); here is a fragment from the the output page.asXml() instruction (the anomaly happens in many tags): <svg xmlns="http://www.w3.org/2000/svg" version="1.1" width="1256" height="362"> <defs> <clipPath id="shielddx"> <rect rx="0" ry="0" fill="none" x="0" y="0" width="9999" height="362" stroke-width="0"/> </clipPath> <clipPath id="shielddy"> <rect fill="none" x="0" y="0" width="NaN" height="NaN"/> </clipPath> </defs> ... If I open TEST_WEB_PAGE in a browser and I open the dev panel attributes are correctly filled up. TEST_WEB_PAGE has been created using Apache wiket and shieldUi. You can fin attached page source, html unit output and chrome page. Can anyone help me?Laura |