Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

126
Vistas
Showing iframe when youtube channel is live

I want to implement a system on my website, where a YouTube livestream is shown in an iframe, if the youtube channel is live (Permanent youtube live links can be created like this: https://www.youtube.com/embed/live_stream?channel= and will always display the livestream, if the channel is active, if not, it will show "Video not available")

Now, since the video not available screen looks oh so good, I want to hide it when the channel is not online and show another element on the website. However, since XSS attacks are a thing, I cannot just select the contents of the iframe and search for the "video not available" or the class of the span and disable the iframe if that element exists, so I have been looking for another solution, but have not found any that are applicable to this useacase.

I have tried with the YouTube API, however this yields no results, as it is only applicable to predetermined video ID's and not static livestreams.

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda