Good night, I want to make an inquiry and see who can help me. First of all I apologize if there is not the right channel to do it … Anyway … what I want to do and I don’t know very well how I can achieve it (I don’t have much knowledge … I’m starting to program) is that click on a link that is inside a header or this link or sorry this particular header change the background (of the headers I have several with a link inside and I want that when pressing one of them the parent header of this link change background) … and then when pressing another link, the first one returns to its previous color and the second one changes the color as well (that is to say, keep only one highlighted among all the headers) Thank you very much in advance …
I think that I do it with javascript but I am not very expert at the moment but if you guide me I will appreciate it …
<nav id="navbar">
<header>
<a href="#Introduccion" class="nav-link"> Introducción </a>
</header>
<header>
<a href="#Estructura_ de_ un_Script" class="nav-link"> Estructura de un Script</a>
</header>
<header>
<a href="#Reglas_Importantes" class="nav-link"> Reglas Importantes </a>
</header>
<header>
<a href="#Comentarios" class="nav-link"> Comentarios </a>
</header>
<header>
<a href="#Funciones" class="nav-link"> Funciones </a>
</header>
<header>
<a href="#Manejo_de_Datos" class="nav-link"> Manejo de Datos </a>
</header>
<header>
<a href="#Manejo_de_Matrices" class="nav-link"> Manejo de Matrices </a>
</header>
<header>
<a href="#url" id="Parametros_de_URL" class="nav-link"> Parámetros de URL </a>
</header>
<header>
<a href="#Control_de_Flujo_de_Datos" class="nav-link"> Control de flujo de Datos </a>
</header>
<header>
<a href="#Manejo_de_Cadenas" class="nav-link"> Manejo de Cadenas </a>
</header>
</nav>