如何让我的div保持固定而不再改变位置?

时间:2022-11-25 14:50:20

At this site there is a slider content. If you change tabs to see that a gray background moves below.

在这个网站上有一个滑块内容。如果您更改标签以查看灰色背景在下方移动。

I want to remain fixed.

我想保持固定。

This is very discreet and you have to look carefully to see.

这是非常谨慎的,你必须仔细看看。

I put a picture to understand better.

我把图片更好地理解了。

http://i60.tinypic.com/2ef8buq.jpg

http://i60.tinypic.com/2ef8buq.jpg

This is code CSS:

这是代码CSS:

.page-id-1637 #top_footer{width:100%;height:531px;background:#EEEEEE;}

This is site:

这是网站:

http://dl.dg-site.com/functionmentes/

http://dl.dg-site.com/functionmentes/

How can i solve this problem?

我怎么解决这个问题?

can you help me please?

你能帮我吗?

Thanks in advance!

提前致谢!

2 个解决方案

#1


1  

If you look at the element with the class .dnd-tabs-wrapper your javascript for the slider defines style="height: auto"; causing it to bounce when the height readjusts.

如果你看一下带有.dnd-tabs-wraper类的元素你的滑块javascript定义了style =“height:auto”;当高度重新调整时,它会反弹。

By default the height of the element is 192px you can solve it by just adding

默认情况下,元素的高度为192px,只需添加即可解决

height: 192px !important to the rule for .dnd-tabs-wrapper.

height:192px!对于.dnd-tabs-wrapper规则很重要。

#2


0  

The issue is that when you change tabs, the height of the div called dnd-tabs-wrapper is being changed through javascript. Since this div is above the .page-id-1637 #top_footer div, it appears to bounce while the height is changing.

问题是,当你更改标签时,调用dnd-tabs-wrapper的div的高度正在通过javascript进行更改。由于此div位于.page-id-1637 #top_footer div之上,因此在高度变化时它似乎会反弹。

You'll need to stop the height from being changed in your javascript. You won't be able to override this with just CSS (unless you use !important).

您需要在javascript中停止更改高度。你将无法用CSS覆盖它(除非你使用!important)。

#1


1  

If you look at the element with the class .dnd-tabs-wrapper your javascript for the slider defines style="height: auto"; causing it to bounce when the height readjusts.

如果你看一下带有.dnd-tabs-wraper类的元素你的滑块javascript定义了style =“height:auto”;当高度重新调整时,它会反弹。

By default the height of the element is 192px you can solve it by just adding

默认情况下,元素的高度为192px,只需添加即可解决

height: 192px !important to the rule for .dnd-tabs-wrapper.

height:192px!对于.dnd-tabs-wrapper规则很重要。

#2


0  

The issue is that when you change tabs, the height of the div called dnd-tabs-wrapper is being changed through javascript. Since this div is above the .page-id-1637 #top_footer div, it appears to bounce while the height is changing.

问题是,当你更改标签时,调用dnd-tabs-wrapper的div的高度正在通过javascript进行更改。由于此div位于.page-id-1637 #top_footer div之上,因此在高度变化时它似乎会反弹。

You'll need to stop the height from being changed in your javascript. You won't be able to override this with just CSS (unless you use !important).

您需要在javascript中停止更改高度。你将无法用CSS覆盖它(除非你使用!important)。