dijit/layout/contentpane中的iframe没有滚动条

dijit/layout/contentpane中的iframe没有滚动条,iframe,dojo,dijit.layout,contentpane,Iframe,Dojo,Dijit.layout,Contentpane,我在dijit/layout/contentpane中有一个IFRAME 当Iframe html呈现大于contentpane大小时,或contentpane处没有滚动条 使用溢出:自动没有帮助。 设置iframe的scrolling=yes将显示不起作用的滚动条。 当我设置iframe时,例如height=1000,contentpane就会提供滚动条。(问题是iframe声明事先不知道它将呈现的内容有多大,以便能够猜测/模糊高度) 有什么建议吗?您最好发布代码,我在ContentPane中

我在dijit/layout/contentpane中有一个IFRAME

当Iframe html呈现大于contentpane大小时,或contentpane处没有滚动条

使用溢出:自动没有帮助。
设置iframe的scrolling=yes将显示不起作用的滚动条。 当我设置iframe时,例如height=1000,contentpane就会提供滚动条。(问题是iframe声明事先不知道它将呈现的内容有多大,以便能够猜测/模糊高度)


有什么建议吗?

您最好发布代码,我在ContentPane中有一个iframe,它工作正常。这是我的代码(重点是你需要设置100%的宽度和高度):

和Css类:

.wpt-report-pane{
    background-color:#ddd;
}

.wpt-iframe{
    border: 0; 
    width: 100%; 
    height: 100%;
}

这里的关键肯定是
宽度:100%
高度:100%
:您需要确保您的内容始终填满
内容窗格。
.wpt-report-pane{
    background-color:#ddd;
}

.wpt-iframe{
    border: 0; 
    width: 100%; 
    height: 100%;
}