From: Jerome <jer...@16...> - 2014-07-27 11:02:09
|
Hi, I'm trying to bulid an application on Facebook with HtmlUnit, So I want to click the buttons on the profile. But I can't find the anchor. After logging into the Facebook, I need to press the button like "About". How could I find the htmlelement? I have tried the function getAnchorByHref(), but failed. I am sure that the attribute was right when using the function. I think it may have some problems with javascript, or I can get this anchor and then click it. By the way, how can I know about the page was loaded successfully by javascript? I have read the article like http://htmlunit.sourceforge.net/faq.html#AJAXDoesNotWorkBut I am still confused about it. Please help to conquer this problem, thanks! Exception in thread "main" com.gargoylesoftware.htmlunit.ElementNotFoundException: elementName=[a] attributeName=[href] attributeValue=[https://www.facebook.com/profile.php?id=100008214242553&sk=about] |