挑战:从iframe内部调用父Javascript函数? [英] A Challenge: Call parent Javascript function from inside an iframe?
问题描述
嗨天才(或者是genii,或者是精灵)
挑战如上所述。我有一个带iframe的页面,并且
需要调用* parent *页面中的JS函数,*来自iframe内部的*。
(它适用于谷歌地图,但我不会厌烦你的复杂性,
,因为它不会影响这个问题)。
>
Mochas对能够解决这个问题的人表示赞赏。
Ta。
Chris Ianson写道:嗨天才(或者是genii,或者是精灵)
挑战如上所述。我有一个包含iframe的页面,并且需要在* parent *页面中调用JS函数,*来自iframe内部的*。
(这是Google的用途)地图,但我不会厌倦你的复杂性,因为它不会影响这个问题。
Mochas对任何能够解决这个问题的人都感到荣幸。
仍然鞭打iframe''死马''我明白了。
parent.yourfunction();
不要尝试申请专利...
-
保重,
Jonathan < br $>
-------------------
小作品工作室
http://www.LittleWorksStudio.com
" Jonathan N.小" < LW ***** @ centralva.net>在消息中写道
news:44 ********************** @ news.centralva.net ..
< blockquote class =post_quotes>仍在鞭打iframe''死马''我明白了。
:(由''死马''我认为你的意思''现在在所有
浏览器中完美运作''。
parent.yourfunction();
遗憾的是,这似乎不适用于Google Maps API。是否还有其他
方法可以调用JS从父框架?
不要尝试为它申请专利...
太对了,我已经有足够的了。 ..
TIA :)
Chris Ianson写道:" Jonathan N. Little ; < LW ***** @ centralva.net>在消息中写道
新闻:44 ********************** @ news.centralva.net ..
仍在鞭打iframe''死马''我明白了。
:(通过''死马''我认为你的意思''现在在所有人中完美地工作/> browsers''。
parent.yourfunction();
遗憾的是,这似乎不适用于Google Maps API。是否还有其他方法可以从父框架调用JS?
http://www.google.com/apis/maps/documentation/
Google Maps API文档
-
保重,
Jonathan
------------------ -
小作品工作室
http://www.LittleWorksStudio。 com
Hi geniuses (or is that genii, or genies)
The challenge is as above really. I have a page with an iframe in it, and
need to call a JS function in the *parent* page, *from* inside the iframe.
(It''s for Google Maps, but I won''t bore you with the complexities of that,
as it doesn''t affect the question).
Mochas kudos to anyone able to solve this widdle.
Ta.
Chris Ianson wrote:Hi geniuses (or is that genii, or genies)
The challenge is as above really. I have a page with an iframe in it, and
need to call a JS function in the *parent* page, *from* inside the iframe.
(It''s for Google Maps, but I won''t bore you with the complexities of that,
as it doesn''t affect the question).
Mochas kudos to anyone able to solve this widdle.
Still flogging the iframe ''dead horse'' I see.
parent.yourfunction();
Don''t try patenting it though...
--
Take care,
Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
"Jonathan N. Little" <lw*****@centralva.net> wrote in message
news:44**********************@news.centralva.net.. .
Still flogging the iframe ''dead horse'' I see.
:( By ''dead horse'' I assume you mean ''now working perfectly in all
browsers''.
parent.yourfunction();
Sadly this doesn''t seem to work for Google Maps API. Are there any other
methods to call JS from the parent frame?
Don''t try patenting it though...
Too right, I have enough of them already...
TIA :)
Chris Ianson wrote:"Jonathan N. Little" <lw*****@centralva.net> wrote in message
news:44**********************@news.centralva.net.. .Still flogging the iframe ''dead horse'' I see.
:( By ''dead horse'' I assume you mean ''now working perfectly in all
browsers''.parent.yourfunction();
Sadly this doesn''t seem to work for Google Maps API. Are there any other
methods to call JS from the parent frame?
http://www.google.com/apis/maps/documentation/
Google Maps API Documentation
--
Take care,
Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
这篇关于挑战:从iframe内部调用父Javascript函数?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!