Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/kotlin/3.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
Twitter bootstrap Twitter引导中的自定义对象_Twitter Bootstrap - Fatal编程技术网

Twitter bootstrap Twitter引导中的自定义对象

Twitter bootstrap Twitter引导中的自定义对象,twitter-bootstrap,Twitter Bootstrap,对于一个容器,我有以下CSS,该容器假定位于给定位置的图像顶部: .jumbotron .container { position: absolute; right: 0; bottom: 0; left: 0; top:75px; } .jumbotron .caption{ position: static; max-width: 750px; padding: 10px; margin-bottom: 200px;

对于一个容器,我有以下CSS,该容器假定位于给定位置的图像顶部:

.jumbotron .container {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    top:75px;
}

.jumbotron .caption{
    position: static;
    max-width: 750px;
    padding: 10px;
    margin-bottom: 200px;
    background: rgba(51, 51, 51, 0.65) !important;
    margin-top: 50px;
}
这将在示例站点上创建以下内容:

你所看到的是巨大的巨磁龙图像,上面有一个不透明的正方形。向下调整屏幕大小,使菜单进入移动友好状态,一切看起来都相对良好,现在打开菜单


不透明正方形不会随图像向下移动,而是停留在一个位置。如何使其随图像移动并保留其原始位置?

位置:相对
添加到特定的jumbotron