开发者

Getting iframe URL location from parent document

I have document with iframe. I have no problem setting iframe's location by using this:

  $('#iframe').attr('src', 'http://www.another-domain-site.com');

When user navigates a few pages in that iframe, then I want to get back URL where he ends up. But when the SRC attribute of the iframe never changes from what I initially have set.

Is there a way how to get iframe's location when it changes or there is no way aroun开发者_C百科d same-domain policy ?

I have one more question on my mind considering question above - is there a way how browser could ask user for permission to allow this type of requests ? The same way Chrome extensions ask for extended permissions ?


I am sorry, after more searching I've found someone ask exactly same question here and the short answer is: "Its not possible".

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜