<?php
# Which page is this header being loaded on?
$page = !empty($page)? $page: "home";

#Show the home link if you are not on the home page
$homeLink = $page != "home"? "<a href=\"".base_url()."\">Home</a> &nbsp;&nbsp;|&nbsp;&nbsp; ": "";
#Show the other links as active if on that page
$aboutLink = $page != "about_us"? "<a href=\"".base_url()."/Page/about_us\">About TMIS</a>": "<span class='label'>About TMIS</span>";
$faqsLink = " &nbsp;&nbsp;|&nbsp;&nbsp; ".($page != "faqs"? "<a href=\"".base_url()."/Page/faqs\">FAQs</a>": "<span class='label'>FAQs</span>");
$verifyLink = " &nbsp;&nbsp;|&nbsp;&nbsp; ".($page != "verify"? "<a href=\"".base_url()."/Page/verify\">Verify</a>": "<span class='label'>Verify</span>");
$logoutLink = ($page != "login" && isset($_SESSION['__user_id'])? " &nbsp;&nbsp;|&nbsp;&nbsp; <a href=\"".base_url()."/Account/logout\">Logout</a>": "");

?>
<tr>
    <td colspan="2" class="whitebg"><div class="logo tmis-logo-top"><a href="<?php echo base_url();?>"><img src="<?php echo base_url();?>/assets/images/tmis-logo.svg" alt="TMIS logo" border="0"></a></div><div class="loginform"><?php echo $homeLink.$aboutLink.$faqsLink.$verifyLink.$logoutLink;?></div></td>
  </tr>
  


  <tr><td colspan="2"><div class="greybg topwhiteborder centrallinks" style="text-align:center; padding-top:10px;padding-bottom:10px;"><?php echo $homeLink.$aboutLink.$faqsLink.$verifyLink.$logoutLink;?></div></td></tr>
