Set iframe to height of content for remote content

后端 未结 6 1936
时光取名叫无心
时光取名叫无心 2021-01-12 11:59

The question of how to make your iframe fit 100% of your content (using JavaScript) has been answered on the forum already... for iframes displaying content from the sam

6条回答
  •  梦毁少年i
    2021-01-12 12:30

    not the best solutions but you can try:

    javascript to write iframe, in iframe app set the current height in url #h700 for 700px etc; then use a loop to listen for that change on host site "in the javascript" to read the src="url#h700" and set the height of the iframe by that.

提交回复
热议问题