5 if (window
.testRunner
) {
6 testRunner
.dumpAsText();
7 testRunner
.waitUntilDone();
12 var txt
= document
.createTextNode(message
);
13 document
.getElementById("logger").appendChild(txt
);
14 document
.getElementById("logger").appendChild(document
.createElement('br'));
19 if (!sessionStorage
.secondPageReached
) {
20 document
.getElementById("firstInput").value
= "SuperSeekritValue";
21 document
.getElementById("secondInput").value
= "SuperSeekritValue";
22 // Location changes need to happen outside the onload handler to generate history entries.
23 setTimeout(function() {window
.location
= "resources/autocomplete-cleared-on-back2.html";}, 0);
27 sessionStorage
.removeItem("secondPageReached");
29 log("Input value 1 - " + document
.getElementById("firstInput").value
);
30 log("Input value 2 - " + document
.getElementById("secondInput").value
);
32 if (window
.testRunner
)
33 testRunner
.notifyDone();
38 <body onload=
"runTest();">
39 This tests whether or not form input values that are designated
autocomplete=
"off" retain their values after a navigation away from the page then returning back to it via the back button.
40 <form autocomplete=
"off">
41 <input type=
"text" id=
"firstInput"/>
44 <input autocomplete=
"off" id=
"secondInput"/>
46 <div id=
"logger"></div>