Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/css/36.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_Css - Fatal编程技术网

尝试在html中对齐表和面板

尝试在html中对齐表和面板,html,css,Html,Css,我试图在屏幕的右侧获得四个面板,在这些面板的左侧获得一个表格。我的问题是当表格不够长时,面板会移动到表格下方,而不是停留在左侧。我使用的是引导主题 <div class="row"> <!-- Start Of Projects Table --> <div class="col-lg-8 pull-right"> <!--table--> </div> <!-- End of pro

我试图在屏幕的右侧获得四个
面板
,在这些面板的左侧获得一个
表格
。我的问题是当
表格
不够长时,
面板
会移动到
表格
下方,而不是停留在左侧。我使用的是引导主题

<div class="row">
    <!-- Start Of Projects Table -->
    <div class="col-lg-8 pull-right">
       <!--table-->
    </div>
    <!-- End of projects table -->
    <div class="col-lg-4 pull-left settings"> 
       <!--Panel Code -->
    </div>
    <div class="col-lg-4 pull-left settings"> 
       <!--Panel Code -->
    </div>
    <div class="col-lg-4 pull-left settings"> 
       <!--Panel Code-->
    </div>
    <div class="col-lg-4 pull-left settings"> 
       <!--Panel Code-->
    </div>
</div>

这是因为您应该在div元素中使用表,对于4个面板,您应该使用另一个“行”


您应该在那里设置家长div。大概是这样的:

 <div class="row">
   <div style="float:left; width:50%;">
     <div class="col-lg-8 pull-right">
       <!--table-->
     </div>
   </div>
   <div style="float:right; width:50%;">
     <div class="col-lg-4 pull-left settings"> 
       <!--Panel Code -->
     </div>
     <div class="col-lg-4 pull-left settings"> 
       <!--Panel Code -->
     </div>
     <div class="col-lg-4 pull-left settings"> 
       <!--Panel Code-->
     </div>
     <div class="col-lg-4 pull-left settings"> 
       <!--Panel Code-->
     </div>
   </div>
</div><!--End of Row-->


引导确实有一个类。如果我记得is
class=“col”
这样,您可以在该行中创建列,并且还可以完全响应。检查此基本夯实。它将帮助你了解更多

请包含所有代码,包括页面上的CSS,这将影响所有内容的显示方式。
 <div class="row">
   <div style="float:left; width:50%;">
     <div class="col-lg-8 pull-right">
       <!--table-->
     </div>
   </div>
   <div style="float:right; width:50%;">
     <div class="col-lg-4 pull-left settings"> 
       <!--Panel Code -->
     </div>
     <div class="col-lg-4 pull-left settings"> 
       <!--Panel Code -->
     </div>
     <div class="col-lg-4 pull-left settings"> 
       <!--Panel Code-->
     </div>
     <div class="col-lg-4 pull-left settings"> 
       <!--Panel Code-->
     </div>
   </div>
</div><!--End of Row-->