Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/html/70.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表单?_Html_Forms_Textbox_Border - Fatal编程技术网

盒子里的html表单?

盒子里的html表单?,html,forms,textbox,border,Html,Forms,Textbox,Border,我想把一个表格放在盒子里,或者在表格周围有一个边框,但是我被卡住了。背景必须是白色的,我想也许一个透明的选项是可以的。有没有哪位专家对如何解决这个问题有一些简单的想法? 包含一些代码 蒂希酒店 正文{背景:白色;} #边界{ 边框:2件纯黑; 位置:绝对位置; z指数:1; 宽度:100px; 高度:80px; 保证金中心:0; 填充:15px; 边界半径:1px; 背景:海军; 不透明度:0.2; } #正文{ 保证金中心:0; z指数:2; 颜色:黑色; 字体大小:粗体; } .. .

我想把一个表格放在盒子里,或者在表格周围有一个边框,但是我被卡住了。背景必须是白色的,我想也许一个透明的选项是可以的。有没有哪位专家对如何解决这个问题有一些简单的想法? 包含一些代码


蒂希酒店
正文{背景:白色;}
#边界{
边框:2件纯黑;
位置:绝对位置;
z指数:1;
宽度:100px;
高度:80px;
保证金中心:0;
填充:15px;
边界半径:1px;
背景:海军;
不透明度:0.2;
}
#正文{
保证金中心:0;
z指数:2;
颜色:黑色;
字体大小:粗体;
}

..
..
//css样式使边框位于窗体的中心
.盒子{
保证金:0自动;
宽度:600px//您可以在%中设置它。
填充:20px;
背景#f9f9f9;
边框:2倍实心#333;
}

..
..
//css样式使边框位于窗体的中心
.盒子{
保证金:0自动;
宽度:600px//您可以在%中设置它。
填充:20px;
背景#f9f9f9;
边框:2倍实心#333;
}
<body>
<div id="border"></div>
<div id="text">Auf dem tisch</div>
</body>

body {background: white;}

#border {
        border: 2px solid black;
        position: absolute;
        z-index: 1;
        width: 100px;
        height: 80px;
        margin-center: 0;
        padding: 15px;
        border-radius: 1px;
        background: navy;
        opacity: 0.2;
    }

#text   {
        margin-center: 0;
        z-index: 2;
        color: black;
        font-weight: bold;
    }
    <div class="box">
<form>
..
..
</form>
</div>

// css style to make border in center of the form

.box{
margin:0 auto; 
width:600px //you can set it in %.
padding:20px;
background:#f9f9f9;
border:2px solid #333;
}