[HtmlUnit] [ htmlunit-Bugs-2890847 ] get about:blank by using a click on a Anchor

View: New views
1 Messages — Rating Filter:   Alert me  

[HtmlUnit] [ htmlunit-Bugs-2890847 ] get about:blank by using a click on a Anchor

by SourceForge.net :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Bugs item #2890847, was opened at 2009-11-02 13:13
Message generated for change (Comment added) made by sdanig
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=448266&aid=2890847&group_id=47038

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: Latest code in SVN
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Konstantin Neubauer (sethus)
Assigned to: Nobody/Anonymous (nobody)
Summary: get about:blank by using a click on a Anchor

Initial Comment:
Hello,
like my sammary say, I'm getting a about:blank Page by using a click on a Anchor.
I create a Junit Test for perform action.
I am calling a page, grab an HtmlElment with a href atribute and proceed a click action on it.
I using HtmlElement instead of HtmlAnchor, becouse sometimes i using a Picture for site navigation.

the page is : http://www.toyota-partner.de/spree-berlin-koepenick/19264/19264/19264/EFA6E16C-40EC-43B9-8F3E-B64AACFB481B/home_premium.html
and anchor is:
<a href="/spree-berlin-koepenick/19265/19265/19265/EFA6E16C-40EC-43B9-8F3E-B64AACFB481B/home_gebrauchtwagen.html" onfocus="if(this.blur)this.blur();">

kind reguards
konstantin

----------------------------------------------------------------------

>Comment By: Daniel Gredler (sdanig)
Date: 2009-11-03 20:58

Message:
The problem is that the click() method returns the page contained by the
current window, and the current window ends up being an empty iframe; I'm
not sure what the correct behavior is here, or whether we should think
about returning the current top level window or something instead, but in
your case you should be able to get the page you want by calling
WebClient.getCurrentWindow().getTopWindow().getEnclosedPage().

----------------------------------------------------------------------

You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=448266&aid=2890847&group_id=47038

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
HtmlUnit-develop mailing list
HtmlUnit-develop@...
https://lists.sourceforge.net/lists/listinfo/htmlunit-develop