I want to what is better way of doing this.Suppose user visit a website he is not yet registered on our website so nav bar shows some options like sign up ,login, help these are options before registration now if user registrated for website after login options on nav bar changes as my profile,account settings,home etc . So how this is done do we have to create two seprate nav bar before and after login or there is another way. after much thinking i have done this
<?php if(!$this->session->userdata('is_login')) : ?>
<div class="collapse navbar-collapse navbar-ex1-collapse">
<ul class="nav navbar-nav navbar-right">
<li><a href="#login-modal"id='modal-launcher' data-toggle="modal">Login</a></li>
<li><a href="<?php echo base_url('Register/index') ?>">Sign-Up</a></li>
<li><a href="#">Help</a></li>
.....
<?php else : ?>
home
my profile //code for displaying these
account settings etc
<?php endif; ?>
Is this is way we do or in any other way.