-1
아래 코드는 this page에 대한 iFrame을 만듭니다. 하지만 바로이로드, 그것은 기본적으로 페이지를 새로 고쳐 나는 iframe을 잃게 :내 iframe의 src가이 페이지가 아닌 이유는 무엇입니까?
<script type="text/javascript">
if (top.location != self.location) {
top.location = self.location.href;
}
</script>
사이트 :
var ifram = '<iframe id="frame" width="100%" height="1" scrolling="yes"></iframe>';
document.write(ifram);
var iframe = parent.document.getElementById("frame");
iframe.height = 600;
iframe.width = '100%';
iframe.src = "http://www.roblox.com/--item?id=19027209";
아마도 귀하의 사이트를 귀하의 사이트에 삽입하기를 원하지 않기 때문일 수 있습니까? google.com과 동일한 트릭을 시도하십시오. – J0HN
제 3 자의 iframe 사이트를 원하지 않기 때문에 프레임이 파열되는 코드가있는 것 같습니다. –