MyBB Internal: One or more warnings occured. Please contact your administrator for assistance.
WebPagetest Forums - Script not working on Firefox/Safari

WebPagetest Forums

Full Version: Script not working on Firefox/Safari
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

I'm trying to run a simple login test using IE/Chrome/Firefox/Safari. But i'm getting really inconsistent data. Generally, the script works on IE and Chrome and doesn't on Firefox and Safari.

When it works, it logs in, when it doesn't work, I can see the user name and password fields are populated, but it appears the form doesn't get submitted.

Any ideas?



//test new site!
// off to the login page...
logData 1
setValue name=LogonForm[uid] username
setValue name=LogonForm[pwd] password
submitForm id=frmLogon
//have also tried submitForm name=logon

Example test runs:
Scripts can only have one step that produces data (, so you're first step should have logData 0 before it

You could try using execAndWait document.getElementById('frmLogon').click() to submit the form to see if it makes any difference.

I had been trying it with both 0 and 1 and saw the same behaviour. I've set it to 0 now but confirm I still see the same problem - firefox is not logging in.


Try doing the form submission with javascript using the execAndWait command. Or better yet, the form fill and submit through script all in one step). That way you can debug locally with firefox and make sure it works before running on WPT (pretty much what Andy recommended).

If pages have pre-submit script that needs to run the behavior can really be tough to debug using the regular commands.
Ah, I see. Ok I'll give it a go and see how I get on.

Thanks again!

I am having a similar issue, in which tests works in Firefox but not in Chrome or IE. I have confirmed that document.querySelector(<selector>).click() works in Chrome Developer Tools.

Any suggestions?

(06-03-2014 07:12 AM)richiemarshall Wrote: [ -> ]Ah, I see. Ok I'll give it a go and see how I get on.

Thanks again!
Can confirm. I'm seeing the similar behavior on the browsers.
I tried using the script, submitForm etc. which did not work

trying each of these steps on debug console in developer tools - works fine.

exec document.getElementById('email').value =""
exec document.getElementById('password').value ="password"
execAndWait document.querySelector('#login-button').click()

document.querySelector works sometimes on Firefox, either on first view or on repeat view. Never together. Chrome, IE & Safari doesn't work.
document.getElementById('login-button').click() -- doesn't work either -- What I see on the agent is that the browser doesn't wait around for the login to complete

if I add a wait time after the click, the browser takes 10 minutes to finish the test, but the results of post login page are not recorded.
Reference URL's