put user actions on dropdown

master
BodgeMaster 2020-04-07 23:43:10 +02:00
parent ab47cb9c50
commit c5c2f920d9
1 changed files with 17 additions and 30 deletions

View File

@ -52,40 +52,27 @@ if (!isset($login)){
}
?>
</li>
<li class="dropdown">
<button class="dropbtn">Dropdown test</button>
<div class="dropdown-content">
<a href="#">Link 1</a>
<a href="#">Link 2</a>
<a href="#">Link 3</a>
</div>
</li>
<li class="right">
<?php
if ($login) {
echo "<a href=\"%CONTENT_DIR%/logout/\">Log out</a>";
<?php
if ($login) {
echo "<li class=\"dropdown right\"><button class=\"dropbtn\"> Put user avatar here </button><div class=\"dropdown-content\"><a href=\"%CONTENT_DIR%/logout/\">Log out</a>";
if ($navbar == "profile") {
echo "<a class=\"active\" href=\"%CONTENT_DIR%/profile/\">Profile</a>";
} else {
if ($navbar == "login") {
echo "<a class=\"active\" href=\"%CONTENT_DIR%/login/\">Log in</a>";
} else {
echo "<a href=\"%CONTENT_DIR%/login/\">Log in</a>";
}
echo "<a href=\"%CONTENT_DIR%/profile/\">Profile</a>";
}
?>
</li>
<li class="right">
<?php
if ($login) {
if ($navbar == "profile") {
echo "<a class=\"active\" href=\"%CONTENT_DIR%/profile/\">Profile</a>";
} else {
echo "<a href=\"%CONTENT_DIR%/profile/\">Profile</a>";
}
echo "</div></li>";
} else {
echo "<li class=\"right\">;
if ($navbar == "login") {
echo "<a class=\"active\" href=\"%CONTENT_DIR%/login/\">Log in</a>";
} else {
echo "<a href=\"%CONTENT_DIR%/login/\">Log in</a>";
}
?>
</li>
}
?>
</ul>
<br />