32 lines
551 B
HTML
32 lines
551 B
HTML
<html>
|
|
<head>
|
|
<script>
|
|
|
|
/*
|
|
* Set the target of the link to 'X_target', where X is the name of
|
|
* this frame.
|
|
*
|
|
* Then click the link.
|
|
*/
|
|
|
|
function click_link()
|
|
{
|
|
var event = document.createEvent('MouseEvent');
|
|
event.initEvent('click', true, true);
|
|
var link = document.getElementById('link');
|
|
link.target = self.name + '_target';
|
|
link.dispatchEvent(event);
|
|
}
|
|
|
|
</script>
|
|
</head>
|
|
|
|
<body onload='click_link();'>
|
|
|
|
<a href="sandboxed-iframe-navigated.html" id="link">
|
|
(link triggered by script)
|
|
</a>
|
|
|
|
</body>
|
|
</html>
|