<nav class="navbar navbar-fixed-top navbar-dark bg-blue-dark">
    <button class="navbar-toggler hidden-sm-up" type="button" data-toggle="collapse" data-target="#exCollapsingNavbar2" aria-controls="exCollapsingNavbar2" aria-expanded="false" aria-label="Toggle navigation">
    <i class="zmdi zmdi-menu"></i>

  </button>

   <a class="navbar-brand hidden-md-up pull-right" href="<?php echo base_url(); ?>">
        <img  class="logo lazy" alt="<?php echo config_item("site_title"); ?>" title="<?php echo config_item("site_title"); ?>" src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" data-src="<?php echo base_url(); ?><?php echo config_item("logo"); ?>">
    </a>


    <div class="container">
        <div class="collapse navbar-toggleable-xs" id="exCollapsingNavbar2">
            <a class="navbar-brand hidden-md-down" href="<?php echo base_url(); ?>">
        <img  class="logo lazy" alt="<?php echo config_item("site_title"); ?>" title="<?php echo config_item("site_title"); ?>" src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" data-src="<?php echo base_url(); ?><?php echo config_item("logo"); ?>">
            </a>
            <?php if($page != 'home'){ ?>
                <form class="form-inline pull-xs-left form-url ">
                    <div class="input-group">
                        <span class="input-group-addon" id="basic-addon1"><i class="zmdi zmdi-globe"></i></span>
                        <input class="form-control input-url" required type="text" placeholder="<?php echo __("Website URL to review"); ?>" />
                        <button class="btn hidden-md-down btn-start" type="submit"><?php echo __("Review"); ?></button>
                    </div>
                </form>
            <?php } ?>

            <ul class="nav navbar-nav pull-md-right ">
               
                <li class="btn-group ">
                        <a class="nav-link dropdown-toggle text-uppercase"  data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"  href="#"><?php echo get_cookie("lang"); ?></a>
                        <div class="dropdown-menu">
                        <?php foreach (config_item("langs") as $key => $value) {
                            ?>
                            <a class="dropdown-item" href="?lang=<?php echo $value["code"]; ?>"><?php echo $value["name"]; ?></a>          
                            <?php
                        }
                        ?>  
                      </div>

                </li>
               
                <li class="nav-item">
                <?php if(!is_logged())
                {
                    ?><a class="nav-link" href="<?php echo base_url(); ?><?php echo config_item("slug_login"); ?>"><?php echo __("Login/Register"); ?></a><?php
                }
                else
                {
                    ?>
                    <div class="btn-group">
                        <a class="nav-link dropdown-toggle active"  data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"  href="#" title="<?php echo _user("email"); ?>"><?php echo _user("names"); ?></a>
                        <div class="dropdown-menu">
                        <?php if(is_sadmin()){ ?>
                        <a class="dropdown-item" href="<?php echo base_url(); ?>admin/dashboard"><?php echo __("Administrator"); ?></a>          
                        <?php } ?>
                        <a class="dropdown-item" href="<?php echo base_url(); ?><?php echo config_item("slug_user"); ?>"><?php echo __("My Profile"); ?></a>          
                        <a class="dropdown-item" href="<?php echo base_url(); ?><?php echo config_item("slug_user"); ?>/bookmarks"><?php echo __("Bookmarks"); ?></a>          
                        <a class="dropdown-item" href="<?php echo base_url(); ?><?php echo config_item("slug_logout"); ?>"><?php echo __("Logout"); ?></a>
                      </div>

                    </div>
                     <?php   
                }
                ?>
                </li>
            </ul>
        </div>

            

    </div>
</nav>
