1$id=$this->session->userdata('user_id');
2<ul class="nav nav-pills">
3 <?php if(isset($id)){ ?>
4 <style type="text/css">#settings{
5display:none;
6} #activity{
7display:inline-block;
8}</style>
9 <li class="nav-item"><a class="nav-link active" href="#activity" data-toggle="tab">Activity</a></li>
10 <?php }else{ ?>
11 <style type="text/css">#activity{
12display:none;
13} #settings{
14display:inline-block;
15}</style>
16 <li class="nav-item"><a class="nav-link active" href="#settings" data-toggle="tab">Settings</a></li>
17 <?php } ?>
18 </ul>
19
20 <div class="tab-pane" id="activity">Activity</div>
21 <div class="tab-pane" id="settings">Settings</div>