Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/html/72.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Html 为什么我的工作粘性div不';不要在内部工作<;iframe>;?_Html_Css - Fatal编程技术网

Html 为什么我的工作粘性div不';不要在内部工作<;iframe>;?

Html 为什么我的工作粘性div不';不要在内部工作<;iframe>;?,html,css,Html,Css,我的页面上有粘性元素。我想怎么用就怎么用。但是当我把页面放在iframe中之后,所有的粘性元素都变成了静态的 试图用溢出:unset更改每个父div,(即使是iframe和upper)也没有帮助 #accessBar { height: 70px; z-index: 100; background: #e8eeff; position: sticky; width: calc(100% - -40px); bottom: -1px; mar

我的页面上有粘性元素。我想怎么用就怎么用。但是当我把页面放在iframe中之后,所有的粘性元素都变成了静态的

试图用
溢出:unset更改每个父div,(即使是iframe和upper)也没有帮助

#accessBar {
    height: 70px;
    z-index: 100;
    background: #e8eeff;
    position: sticky;
    width: calc(100% - -40px);
    bottom: -1px;
    margin-left: -30px;
}

IFrame
的样式应该在
IFrame
本身中。 请注意,
Sticky
规则将应用于
IFrame


iframe{height:200px;border:0;}
您的页面包含一些内容


能否添加更多详细信息和
html
?我不确定是否可以。有很多html代码。这里不像往常一样50岁。但是确实有很多。试着添加必要的内容来澄清您的问题或创建JSFIDLE