是的,主人,我想使带有引导程序的用户个人资料页与卡和选项卡面板并排放置,但不成功,这是我的代码,请帮忙。
<div class="col-md-2">
<div class="card">
<h5 class="card-header text-center"><i class="fa fa-user"></i> '.$_SESSION['user']->username.'</h5>
<img src="http://www.bkpsdm-boltim.info/wp-content/uploads/2019/01/no_photo.jpg" class="card-img-top" alt="...">
<div class="card-body">
<a target="_self" href="http://www.facebook.com" class="fab fa-facebook"></a> <a target="_self" href="http://www.facebook.com" class="fab fa-facebook-messenger"></a> <a target="_self" href="http://www.twitter.com" class="fab fa-twitter"></a> <a target="_self" href="http://www.whatsapp.com" class="fab fa-whatsapp text-success"></a>
<label class="card-text">With supporting text below as a natural lead-in to additional content.</label>
<a href="#" class="btn btn-primary">Go somewhere</a>
</div>
<div class="card-footer">
<h6><small class="text-muted">Register Date:'.date('Y-m-d H:i:s', $_SESSION['user']->registerdate).'</small></h6>
</div>
</div>
</div>
<div class="col-md-10">
<nav>
<div class="nav nav-tabs" id="nav-tab" role="tablist">
<a class="nav-item nav-link active" id="nav-home-tab" data-toggle="tab" href="#nav-home" role="tab" aria-controls="nav-home" aria-selected="true">Home</a>
<a class="nav-item nav-link" id="nav-profile-tab" data-toggle="tab" href="#nav-profile" role="tab" aria-controls="nav-profile" aria-selected="false">Profile</a>
<a class="nav-item nav-link" id="nav-contact-tab" data-toggle="tab" href="#nav-contact" role="tab" aria-controls="nav-contact" aria-selected="false">Contact</a>
</div>
</nav>
<div class="tab-content" id="nav-tabContent">
<div class="tab-pane fade show active" id="nav-home" role="tabpanel" aria-labelledby="nav-home-tab">...</div>
<div class="tab-pane fade" id="nav-profile" role="tabpanel" aria-labelledby="nav-profile-tab">...</div>
<div class="tab-pane fade" id="nav-contact" role="tabpanel" aria-labelledby="nav-contact-tab">...</div>
</div>
</div>
答案 0 :(得分:0)
您正在寻找类似的东西吗?
<link href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" rel="stylesheet" />
<div class="container-fluid mt-5">
<div class="row justify-content-md-center">
<div class="col-5 col-md-4 col-lg-2">
<div class="card">
<h5 class="card-header text-center"><i class="fa fa-user"></i> '.$_SESSION['user']->username.'</h5>
<img src="http://www.bkpsdm-boltim.info/wp-content/uploads/2019/01/no_photo.jpg" class="card-img-top" alt="...">
<div class="card-body">
<a target="_self" href="http://www.facebook.com" class="fab fa-facebook"></a>
<a target="_self" href="http://www.facebook.com" class="fab fa-facebook-messenger"></a>
<a target="_self" href="http://www.twitter.com" class="fab fa-twitter"></a>
<a target="_self" href="http://www.whatsapp.com" class="fab fa-whatsapp text-success"></a>
<label class="card-text">With supporting text below as a natural lead-in to additional content.</label>
<a href="#" class="btn btn-primary">Go somewhere</a>
</div>
<div class="card-footer">
<h6><small class="text-muted">Register Date:'.date('Y-m-d H:i:s', $_SESSION['user']->registerdate).'</small></h6>
</div>
</div>
</div>
<div class="col-7 col-md-5 col-lg-10">
<nav>
<div class="nav nav-tabs" id="nav-tab" role="tablist">
<a class="nav-item nav-link active" id="nav-home-tab" data-toggle="tab" href="#nav-home" role="tab" aria-controls="nav-home" aria-selected="true">Home</a>
<a class="nav-item nav-link" id="nav-profile-tab" data-toggle="tab" href="#nav-profile" role="tab" aria-controls="nav-profile" aria-selected="false">Profile</a>
<a class="nav-item nav-link" id="nav-contact-tab" data-toggle="tab" href="#nav-contact" role="tab" aria-controls="nav-contact" aria-selected="false">Contact</a>
</div>
</nav>
<div class="tab-content" id="nav-tabContent">
<div class="tab-pane fade show active" id="nav-home" role="tabpanel" aria-labelledby="nav-home-tab">...</div>
<div class="tab-pane fade" id="nav-profile" role="tabpanel" aria-labelledby="nav-profile-tab">...</div>
<div class="tab-pane fade" id="nav-contact" role="tabpanel" aria-labelledby="nav-contact-tab">...</div>
</div>
</div>
</div>
</div>