I need a solution for auto-adjusting the width
and height
of an iframe
to barely fit its content. The point is that t
I slightly modified Garnaph's great solution above. It seemed like his solution modified the iframe size based upon the size right before the event. For my situation (email submission via an iframe) I needed the iframe height to change right after submission. For example show validation errors or "thank you" message after submission.
I just eliminated the nested click() function and put it into my iframe html:
Worked for me, but not sure about cross browser functionality.