5 document.cookie = 'foo=baz';
7 // If there is a cookie prompt showing, then reading from document.cookie
8 // should block until the dialog is closed.
9 if (document.cookie.indexOf('foo') == -1) {
10 document.title = 'cookie blocked';
12 document.title = 'cookie allowed';
17 <body onload="setCookie();">