Concept
My idea is to create a website with a navigation menu where only one section is visible at a time. Each section would become visible upon clicking a specific button in the navigation bar.
Challenge
I attempted to achieve this using the following code:
$(document).ready(function show(){
document.getElementById(#showElement).style.display= "block";
})
The issue I am facing with this code is that I am unable to determine which button was clicked and subsequently identify the sections that should have display:none;
applied to them.
Given my limited experience with JavaScript, I am unsure if this task is feasible and how I would go about implementing it.
As someone new to JavaScript, any guidance you can provide would be greatly appreciated. Thank you in advance.