Loading Audio Element After Dynamically Changing the Source

前端 未结 3 700
攒了一身酷
攒了一身酷 2021-01-02 20:16

I have a couple of audio elements that appear in the body of my page. They look like this.

      
3条回答
  •  一生所求
    2021-01-02 20:59

    This is tricky. I would try replacing the whole element instead of just changing its source. This way, the new audio element hasn't been added to the page, so it will be forced to load the file.

提交回复
热议问题