kylebellamy
Programmer
I am playing with layers and have no problem with creating the DIV to be hidden and getting them to show up on a link click.
Here's the code I'm using:
The thing is that I have each layer set to have a translucent background at 58% black so when multiple links are clicked, you can see the DIVs overlapping.
How do I modify the code above to check for and hide any other layers when a link is clicked to show a new layer? I'm going to use this as the main way I display data for the site so they need to be hidden. So if the Artwork layer is showing and the Contact layer link is clicked, the Artwork layer is hidden and the Contact one shows.
Thanks in advance!
Here's the code I'm using:
Code:
function ShowContent(d) {
if(d.length < 1) { return; }
document.getElementById(d).style.display = "block";
}
The thing is that I have each layer set to have a translucent background at 58% black so when multiple links are clicked, you can see the DIVs overlapping.
How do I modify the code above to check for and hide any other layers when a link is clicked to show a new layer? I'm going to use this as the main way I display data for the site so they need to be hidden. So if the Artwork layer is showing and the Contact layer link is clicked, the Artwork layer is hidden and the Contact one shows.
Thanks in advance!