Div不会随着孩子的桌子而扩大

时间:2014-05-04 17:00:38

标签: php html css

http://prntscr.com/3g5e9i

div不会随着孩子的内容而扩展,我在谷歌上找不到解决方案。

代码仍然凌乱且未完成

        <div style="width:600px;" class="userprofile">
        <?php if($_SESSION['profilepage']=="vievprofile"){// VIEV PROFILE
        addPointer($pointer,174,145);

            $stat1;
            $stat2;
            $stat3;
            $stat4;
            $stat5;
            $stat6;
            ?>
            <div class="avatar"><?php echo $tUserAvatar;?></div></div>
            <div class="userprofiletitle"><?php echo $tUser."'s profile"; ?></div>
            <div style="position:absolute;top:50px;left:150px; height:100%">
                <table class="userstats">
                    <tr>
                        <td>stat1 </td> <td> stat2 </td>
                    </tr>
                    <tr>
                        <td>stat3</td><td>stat4</td>
                    </tr>
                    <tr>
                        <td>stat5</td><td>stat6</td>
                    </tr>
                </table>

            </div>
        <?php }if($_SESSION['profilepage']=="editprofile" && $_SESSION['login']==$tUser){//EDIT PROFILE
        addPointer($pointer,199,145);?>
        <?php }if($_SESSION['profilepage']=="editavatar" && $_SESSION['login']==$tUser){//EDIT AVATAR
        addPointer($pointer,224,145);?>
        <?php }if($_SESSION['profilepage']=="editsettings" && $_SESSION['login']==$tUser){//EDIT SETTINGS
        addPointer($pointer,249,145);?>
        <?php } ?>
        </div>

CSS

.userstats{
    font-weight:bold;
    font-size:16;
    empty-cells:hide;
}

.userstats td{
    width: 250px;

}

.userprofile{
    position:fixed; top:170px; left:270px;
    font-size: 16;
    border:3px;
    border-style:solid;
    border-color:black;
    background: rgb(0, 160, 0);
    background: rgba(0, 160, 0, 0.8);

}

它不会让我发布所以我添加一些无用的非主题相关文本。

有人错过了这个,所以我会再发一次。 http://prntscr.com/3g5e9i这就是问题的样子

0 个答案:

没有答案
相关问题