How to execute function after the inner frame has been loaded?
I have th开发者_JAVA技巧is problem,
- I have an html that contains an inner frame.
I have a jquery statement that contains function that will execute after the whole page has been rendered like this:
$(window).ready(function(){ //statements here });
Using the function above I want to check if the inner frame has already been rendered. That is I want to check if the inner frame has already load the inner page and displayed the inner page COMPLETELY. It has a similar effect with
$(window).ready();
So my question is,
- How do i code it? Because i already tried this way
$("_iframe id_").ready(_function here for checking_);
and it doesn't work :(
Does this work?
$('#iframe').load(function() {
// Foo.
});
精彩评论