Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

216
Visualizações
How To Skip Silence in Audio In JavaScript

I have searched a lot about this but I can't find any solid code snippet of anything like that that explains how this would work.

Google Podcasts web app does this and I would like to learn how this works for a web app I'm building.

A lot of podcast apps let you skip silences even as small as half a second long silences.

How can I do this with JavaScript?

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

You can try this:

    <script>
    function skip(s) {
    var aud = document.getElementById("myAudio");
    aud.currentTime = vid.currentTime +  s;
    }
    </script>
<script>
while true {if document.getElementById('myAudio').currentTime == 5 {skip(0.5)}}
    <audio id='myAudio' src=potcast.mp3 controls><br>
    <button onclick=skip(0.5)>Skip</button> <!-- 0.5s = skip(0.5) -->

How to use it?

  1. You copy the code into your project. (Could be a HTML-Page)
  2. Style the Button
  3. Set the skip duration to 0.5 (or wat you want)
  4. Set the src= to your audio-file-name
  5. Style the audio player (or use your potcast-plyer)
  6. Try it.
about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda