Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

177
Views
problema relacionado con la corrección de un encabezado con HTML y JavaScript: se necesita ayuda

Intento arreglar un encabezado pegajoso con html y JavaScript, pero no funciona. Encuentre mi código a continuación.

 <header> <a href="#" class="logo"><span>P</span>etits<span>S</span>oins</a> <ul class="navbar"> <li><a href="#">Accueil</a></li> <li><a href="#">Services</a></li> <li><a href="#">Qui sommes nous</a></li> <li><a href="#">Contact</a></li> </ul> </header> <script type="text/javascript"> window.addEventListener('scrol', function(){ const header = document.querySelector('header'); header.classList.toggle("sticky", window.scrollY > 0); }); </script> header.sticky{ background: #fff; padding: 10px 10px; box-shadow: 0px 5px 20px rgba(0, 0, 0, 0.05); position: -webkit-sticky;/*Safari*/ position: sticky; top: 0; } header.sticky .logo{ color: #000; } header.sticky .navbar li a{ color: #000; } header.sticky .navbar li a:hover{ color:#333; border-bottom: 2px solid #333; }

¿Podrían por favor ayudarme a encontrar una solución para que funcione?

gracias andrea

about 4 years ago · Santiago Gelvez
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!