I have a problem running Selenium IDE over one of my AJAX pages. There is a HTML button with a javascript onclick submit that causes a new form element to appear once the button is clicked. The button also only appears through AJAX after a select value has been selected on a previously displayed drop down.
Selenium sees the button appear and thinks it clicks it, but the click doesn’t actually work.
I temporarily do not have access to the source code for reasons I won’t get into. I know I’m probably being a bit vague here… I’ll try to post more specifics when I can.
Cheers
EDIT: Just to clarify, I’m using the waitForVisible command on the button, which passes, and then the click, which also passes, but then it gets stuck on the next element which is making a selection from a drop down box. Selenium thinks it’s doing this but it’s not 🙁
If the click of the button is simply not being recorded you will have to go into the code to manually write that step in while specifying the correct XPath expression or DOM path. Selenium could be auto generating an incorrect DOM path, but the only way to be sure is to look at the code.
The most probable answer is a timing issue. Selenium tends to fire steps faster than the DOM can render changes, and that causes errors. You might want to try specifying a two second pause directly between the generation of the button and the clicking of the button.
If the problem is something different you will have to be more specific.