在当前页面显示iframe弹窗,a链接跳转
<!DOCTYPE html>
<html>
<head>
<title></title>
</head>
<body>
<div id="con" style="width: 800px; height: 700px; border: 2px solid red; padding: 10px 0 10px 10px; display: none; overflow: hidden;">
<i id="close" style="width: 30px; height: 30px; background: #ccc; color: #fff; float: right; font-size: 26px; line-height: 30px; text-align: center; font-style: normal;">×</i>
<iframe id="myFrameId" style="width: 100%; height: 100%;" name="myFrameName" scrolling="" frameborder="0"></iframe>
</div>
<div id="ac">
跳转
<a id="a" href="http://www.hzgufen.com" target="myFrameName"></a>
</div>
<script type="text/javascript">
document.getElementById('ac').onclick = function () {
document.getElementById('con').style.display = 'block'
document.getElementById('a').click()
}
document.getElementById('close').onclick = function () {
document.getElementById('con').style.display = 'none'
}
</script>
</body>
</html>