i am very new in html ,JS and php . I have created a page that has only a sidebare menu with some options and there are some users logged in(in the log in phase i used php with mySQL for my base in an other file):
<div id="mySidenav" class="sidenav">
<a href="javascript:void(0)" class="closebtn" onclick="closeNav()">×</a>
<a id="concerts"href="#">Concerts</a>
<a id="favorites"href="#">Favorites</a>
<a id="organizer"href="#">Orginizer</a>
<a id="admin"href="#">Administration</a>
</div>
<span style="font-size:30px;cursor:pointer" onclick="openNav()">☰ </span>
<script>
function openNav() {
document.getElementById("mySidenav").style.width = "250px";
}
function closeNav() {
document.getElementById("mySidenav").style.width = "0";
}
document.getElementById("concerts").onclick = function () {
location.href = "concerts.php";
};
My problem here is that i need to exclude some users lets say based on their names by clicking on the 'Concerts' option from my menu . How can i do that in javascript ?
i thought of php SESSION but nothing seems to work .
Any help would be valuable and i am really sorry if the answer is too obvious.