Benn
Benn

Reputation: 5023

Execute the mootools function faster

I am trying to set iframe height onload , here is example

http://jsfiddle.net/hN6z3/1/

It works only when the site has loaded already but I need it to be set before it loads.

Upvotes: 1

Views: 69

Answers (1)

Shawn Steward
Shawn Steward

Reputation: 6825

The only way you can set the height before the page loads is to do it from your server side script or in the straight HTML/CSS. If you use JavaScript, it will require some of the page to be loaded before it will run. You can't calculate the height in JavaScript until the page is actually loaded otherwise it will be less than what you expect.

Upvotes: 2

Related Questions