I am running a platform that provides simple forms and simple outputs for a bunch of clients who embed this features in there webpages by iframe. As these forms and outputs tend to grow over common screen heights, the idea is to let the main scrollbar of the embedding webpage also control the scrollbar of the embedded iframe, i.e. if the scrollbar reaches the iframe, the embedding page stops to scroll, but the iframe is scrolled till it reaches its bottom. Afterwards, the embedding page will be continued to be scrolled. Embedding pages and my platform are on different domains.
It is possible for me to include some (perferently vanilla) javascript besides the HTML code for iFrame.
My questions:
1.) Is there a framework to handle control of the scrollable elements? (I have seen such things on a newspaper website, but it isn’t online anymore.)
2.) Am I running into some Cross-Domain same origin policy issues anyway?