Do not announce robot account token before account ID is available
[chromium-blink-merge.git] / chrome / test / data / safe_browsing / prefetch_malware.html
blobf55336defe4f8bc47dc6cedb8525548966a1aa13
1 <html>
2 <head>
3 <script>
4 function log(message)
6 var item = document.createElement("li");
7 item.appendChild(document.createTextNode(message));
8 document.getElementById("console").appendChild(item);
11 function return_malware_prefetch() {
12 var pathArray = window.location.pathname.split('/');
13 var newPathname = "";
14 for ( i=0; i < pathArray.length - 1; i++ ) {
15 newPathname += pathArray[i];
16 newPathname += "/";
18 newPathname += "malware.html";
19 var href = window.location.protocol + "//" + window.location.host + newPathname;
20 var link = document.createElement("link");
21 link.rel = "prefetch";
22 link.href = href;
23 log(link.outerHTML);
24 return link; }
26 function add_prefetch(element) {
27 var head = document.getElementsByTagName("head")[0];
28 head.appendChild(element);
30 </script>
31 </head>
32 <body onload="add_prefetch(return_malware_prefetch());">
33 This page is not malware, <a href="malware.html">but this page is</a>. If
34 prefetches don't trigger safe browsing interstitials, then this page
35 should work in a dandy manner.
36 <p><ol id="console"></ol></p>
37 </body>
38 </html>