WebPagetest Forums
Why does a script work on FF and Chrome but not on IE - Printable Version

+- WebPagetest Forums (https://www.webpagetest.org/forums)
+-- Forum: WebPagetest (/forumdisplay.php?fid=7)
+--- Forum: General Discussion (/forumdisplay.php?fid=25)
+--- Thread: Why does a script work on FF and Chrome but not on IE (/showthread.php?tid=13579)



Why does a script work on FF and Chrome but not on IE - pganti - 03-02-2015 05:48 PM

There's this weird problem where the following script would work nicely on FF and Chrome but does not work on any version of IE. I tried to debug but no avail and hence seeking your help on this.

Succesful runs:

FF: http://www.webpagetest.org/result/150301_1Z_866/
Chrome: http://www.webpagetest.org/result/150301_70_2CC/

Failed Runs:
IE 11: http://www.webpagetest.org/result/150301_4F_2J6/
IE 9 : http://www.webpagetest.org/result/150301_E3_86C/
IE 8: http://www.webpagetest.org/result/150302_AW_C14/[/quote]

Here's my script
Quote:combineSteps
navigate http://www.insight.com/
setValue id=searchText "hp laserjet pro"
clickAndWait id=searchBtn
clickAndWait id=CE749AR#BGJ_^^HP LaserJet Pro P1606DN - printer - monochrome - laser - remarketed
execAndWait submitPPPSubmission('main', 'CE749AR#BGJ',false);
execAndWait location.href = '/insightweb/viewCart’;
setValue id=j_username keynoteuser1
setValue id=j_password password1
execAndWait InsightNavigation.validateLoginSmallWindow();
execAndWait callShipBillPayPage('shippingOrder’);


What gives on IE?


RE: Why does a script work on FF and Chrome but not on IE - andydavies - 03-03-2015 06:56 PM

I tried this but it fails in IE too - so you might need to walk through the DOM scripting in IE

Code:
combineSteps
navigate    http://www.insight.com/
exec document.getElementById('searchText').value="hp laserjet pro"
execAndWait    document.getElementById('searchBtn').click()
execAndWait    document.getElementById('CE749AR#BGJ_^^HP LaserJet Pro P1606DN - printer - monochrome - laser - remarketed').click()
execAndWait    submitPPPSubmission('main', 'CE749AR#BGJ',false);
execAndWait    location.href = '/insightweb/viewCart';
exec    document.getElementById('j_username').value="keynoteuser1"
exec    document.getElementById('j_password').value="password1"
execAndWait    InsightNavigation.validateLoginSmallWindow();
execAndWait    callShipBillPayPage('shippingOrder');

One thing I did notice while looking at it is that a couple of the strings end with rather than '

Might have another poke at it later if I get the chance


RE: Why does a script work on FF and Chrome but not on IE - pganti - 03-06-2015 05:56 AM

(03-03-2015 06:56 PM)andydavies Wrote:  I tried this but it fails in IE too - so you might need to walk through the DOM scripting in IE

Code:
combineSteps
navigate    http://www.insight.com/
exec document.getElementById('searchText').value="hp laserjet pro"
execAndWait    document.getElementById('searchBtn').click()
execAndWait    document.getElementById('CE749AR#BGJ_^^HP LaserJet Pro P1606DN - printer - monochrome - laser - remarketed').click()
execAndWait    submitPPPSubmission('main', 'CE749AR#BGJ',false);
execAndWait    location.href = '/insightweb/viewCart';
exec    document.getElementById('j_username').value="keynoteuser1"
exec    document.getElementById('j_password').value="password1"
execAndWait    InsightNavigation.validateLoginSmallWindow();
execAndWait    callShipBillPayPage('shippingOrder');

One thing I did notice while looking at it is that a couple of the strings end with rather than '

Might have another poke at it later if I get the chance

Let me know if you did. BTW this isnt unique to WebPageTest, I also had Catchpoint Support guys get caught up in the same issue (they use Selenium IDE etc) so definitely points to something on their site