Feature Requests item #1022916, was opened at 2004-09-06 09:28
Message generated for change (Settings changed) made by henryju
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=497985&aid=1022916&group_id=61302
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: Core API
Group: None
Status: Open
Priority: 5
Private: No
Submitted By: Ivan Codarin (codarin)
>Assigned to: Nobody/Anonymous (nobody)
Summary: Access to form elements by ID
Initial Comment:
Dear All,
I use a framework that generates all the form included
input types of any kind.... it gives to all form
elements proprietary names that I cannot discover at
runtime.
So is very difficult to use jwebunit to test this kind
of forms.
But I can use the id attribute for every form element,
button, submit... so now I'm asking you if I can access
(set, get the form values) using the ID...
Now I have a code snipped like this:
private String getNameByID(String ID,WebResponse resp)
{
String result=null;
HTMLElement testo;
try {
testo=resp.getElementWithID("firstname");
result=testo.getName();
}
catch (Exception e)
{
System.out.println("exception...to debug...");
}
return result;
}
I pass tho this method the "ID" and the httpunid
webresponse object to get the "name" of a form element...
I don't think this is an "optimal" solution....
Could you extend jwebunit to get this feature available?
Many thanks
Ivan
----------------------------------------------------------------------
Comment By: Ivan Codarin (codarin)
Date: 2004-09-29 17:02
Message:
Logged In: YES
user_id=442311
I use dbforms, yet another mvc framework.
I have to access to elements by id because this frameworks
writes form.elements with its own names.
thanks
ivan
----------------------------------------------------------------------
Comment By: Jim Weaver (jimweaver)
Date: 2004-09-22 17:17
Message:
Logged In: YES
user_id=619947
Is this tapestry?
If so, it seems like I remember someone posting or telling
me about a way around that problem (fixing form element
names to specific values).
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=497985&aid=1022916&group_id=61302
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
JWebUnit-development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jwebunit-development