<center>
<?php if ( $default->sidebar->local_site_logo ) { ?>
<img src="<?php echo $default->sidebar->local_site_logo_url; ?>" width="80">
<?php } ?>
<?php if ( $default->sidebar->logo && $default->sidebar->logo_url != true  ) { ?>
<img src="<?php echo $default->graphics_url . '/' . $default->sidebar->logo_url ?>" width=80 height=50 border=0 alt="[IMP logo]">
<?php } ?>
</center>

<table border=0><tr><td bgcolor="<?php echo $default->dark_bg ?>">
<font size=2 face="<?php echo $default->font->face; ?>">

<?php if ($menu == IMPMENU_DORMANT): ?>
<br><a href="login.php3?reason=login" target="impmain"><img border="0" align="middle" src="<?php echo $default->graphics_url ?>/login.gif" alt="*" height="18" width="18" hspace="2"><?php echo $lang->login ?></a>

<?php if ($default->signup): ?>
<br><a href="../signup.php3?from_imp=true" target="impmain"><img border="0" align="middle" src="<?php echo $default->graphics_url ?>/logout.gif" alt="*" height="18" width="18" hspace="2"><?php echo $lang->signup ?></a>
<?php endif; ?>

<?php elseif ($menu == IMPMENU_MAIN): ?>

<br><a href="mailbox.php3" target="impmain"><img border="0" align="middle" src="<?php echo $default->graphics_url ?>/inbox.gif" alt="*" height="18" width="18" hspace="2"><?php echo $lang->check_inbox ?></a>
<br><a href="javascript:open_compose_win('')"><img border="0" align="middle" src="<?php echo $default->graphics_url ?>/compose.gif" alt="*" height="18" width="18" hspace="2"><?php echo $lang->compose ?></a>

<?php if ($default->use_db): ?>
  <?php if ($default->user_use_addressbook == true): ?>
    <?php if ($default->use_ldap_search): ?>
      <br><a href="javascript:open_contacts_ldap_win()"><img border="0" align="middle" src="<?php echo $default->graphics_url ?>/addressbook.gif" alt="*" height="18" width="18" hspace="2"><?php echo $lang->contacts ?></a>
    <?php else: ?>
       <br><a href="javascript:open_contacts_win()"><img border="0" align="middle" src="<?php echo $default->graphics_url ?>/addressbook.gif" alt="*" height="18" width="18" hspace="2"><?php echo $lang->contacts ?></a>
     <?php endif; ?>
  <?php else: ?>
    <?php if ($default->use_ldap_search): ?>
      <br><a href="javascript:open_contacts_ldap_noaddy_win()"><img border="0" align="middle" src="<?php echo $default->graphics_url ?>/addressbook.gif" alt="*" height="18" width="18" hspace="2"><?php echo $lang->contacts ?></a>
    <?php endif; ?>
  <?php endif; ?>
<?php else: ?>
  <?php if ($default->use_ldap_search): ?>
    <br><a href="javascript:open_contacts_ldap_noaddy_win()"><img border="0" align="middle" src="<?php echo $default->graphics_url ?>/addressbook.gif" alt="*" height="18" width="18" hspace="2"><?php echo $lang->contacts ?></a>
  <?php endif; ?>
<?php endif; ?>

<br><a href="folders.php3" target="impmain"><img border="0" align="middle" src="<?php echo $default->graphics_url ?>/folder.gif" alt="*" height="18" width="18" hspace="2"><?php echo $lang->folders ?></a>

<?php if ($default->use_db): ?>
<br><a href="prefs.php3" target="impmain"><img border="0" align="middle" src="<?php echo $default->graphics_url ?>/prefs.gif" alt="*" height="18" width="18" hspace="2"><?php echo $lang->prefs ?></a>
<?php endif; ?>

<?php if ($default->v2_database) {
   echo '<p>Horde Management';
   manager_menu_item(MGR_USER_ADD_FRM, 'Add User');
   manager_menu_item(MGR_USER_EDIT_SELECT_FRM, 'Edit User');
   manager_menu_item(MGR_USER_DELETE_SELECT_FRM, 'Delete User');
}
?>

<?php endif; ?>

<?php if (isset($default->faq_url) && $default->faq_url): ?>
<br><a href="<?php echo $default->faq_url ?>" target="_blank"><img border="0" hspace="2" align="middle" src="<?php echo $default->graphics_url ?>/help.gif" width="18" height="18" alt="*"><?php echo $lang->faq ?></a>
<?php endif; ?>

<?php if ($default->problem_reporting): ?>
<br><a href="../problem.php3?from_imp=true" target="impmain"><img border="0" align="middle" src="<?php echo $default->graphics_url ?>/exclamation.gif" hspace="2" width="18" height="18" alt="*"><?php echo $lang->problem ?></a>
<?php endif; ?>

<?php if ($menu == IMPMENU_MAIN): ?>
<p><a href="login.php3?reason=logout" target="impmain"><img border="0" hspace="2" align="middle" src="<?php echo $default->graphics_url ?>/logout.gif" width="18" height="18" alt="*"><?php echo $lang->logout ?></a>
<?php endif; ?>

<?php if ($default->sidebar->local_site_logo && $default->sidebar->logo): ?>
<img src="<?php echo $default->graphics_url . '/' . $default->sidebar->logo_url ?>" width=80 height=50 border=0 alt="[IMP logo]">
<?php endif; ?>

<?php          
if ($extra_menus)
    echo $extra_menus;
?>


</font>
</td></tr></table>

