I have descriptive text saying "Please press play.", and an audio file under it. I already have it so that the audio player disappears after it is done playing, using
jQuery('audio').on('ended', function() { jQuery(this).hide(); });
but I would like it so that the text disappears at the same time as the audio player.
Page 1 / 1
Use the below code:
var that = this;
jQuery('audio').on('ended', function() {
jQuery(this).hide();
jQuery("#"+that.questionId+" .QuestionText").hide();
});
var that = this;
jQuery('audio').on('ended', function() {
jQuery(this).hide();
jQuery("#"+that.questionId+" .QuestionText").hide();
});
Leave a Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.