开发者

redirect an iframe

is it possible to redirect an iframe to display the content of the frame after 2 seconds in a full window(same window, not a new one). 开发者_JS百科I hope for a PHP solution.


You're going to need to use a client side language for that - namely JavaScript.

Here's a start

setTimeout(function() {

    var frameElement = document.getElementById('my-iframe');
    // get iframe URL
    // window.open(iFrameUrl, '_self');

}, 2000);


Looks like you can use the location property of the 'top' object in JavaScript.

This link seems to describe this approach more fully.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜