I'm developing a Dynamic content macro for Confluence Cloud that returns a dynamic HTML table.
Dynamic Content Macro documentation says "If the size of the macro output content size is dynamic, call AP.resize(w,h) immediately after the DOM of your iframe is loaded."
To retrieve width and height of the content, I found the following code on Internet:
var newheight = document.getElementById(id).contentWindow.document .body.scrollHeight; var newwidth = document.getElementById(id).contentWindow.document .body.scrollWidth;
But the frame id is generated dynamically and is not accessible through Context Parameter.
So, how can I adjust i frame width and height to fit with content inside a dynamic content macro ?
More and more people are building their careers with Atlassian, and we want you to be at the front of this wave! Important Dates Start the Certification Prep Course by 2 April 2019 Take your e...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs