[Wtr-general] Cannot access input element
David Schmidt
davids at tower-mt.com
Wed Sep 6 02:12:56 EDT 2006
The lack of any input tags in a view source is easy to explain. I've
found that a view source will only show the *initial* HTML that was sent
to the browser. Any changes due to AJAX or Dynamic HTML will not show
up in a view source, but will show up using development tools which
show you the active DOM.
As to why the button isn't being clicked, it isn't clear from the HTML
below, but perhaps there is something in the onClick() handler that
aborts the effects of the click. One thing I've done in our web
scraping applications is to re-write the HTML before clicking to prevent
some un-necessary events from firing.
David
knoorani at e-xact.com wrote:
> No it is a div with absolute position.
>
>> Sounds like frames to me. True?
>>
>> knoorani at e-xact.com wrote:
>>
>>> Hey all,
>>>
>>> I have a form which I click on to perform an action.
>>>
>>> I get a result back from the action and a screen displays with an OK
>>> option.
>>>
>>> Inspecting the code through view source does not show me any input tags,
>>> yet when I download Dev tools for firefox and view the generated source
>>> I
>>> see the elements like
>>>
>>>
>>> <div class="alphababe_buttons">
>>> <input value="OK" onclick="Dialog.cancelTalker()" class="cancel_button"
>>> type="button"></div>
>>>
>>> but if I add
>>> ie.button(:value,"OK").click
>>> nothing happens
>>>
>>> Any help would be much appreciated
>>>
More information about the Wtr-general
mailing list