Feature Requests item #1022916, was opened at 2004-09-06 09:28
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=497985&aid=1022916&group_id=61302

Category: None
Group: None
Status: Open
Priority: 5
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

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

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 BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=5047&alloc_id=10808&op=click
_______________________________________________
Jwebunit-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jwebunit-development

Reply via email to