I'm currently using jquery.srt.js to display subtitles for some videos that I have.
What I am trying to accomplish is displaying the whole text file of the subtitles in a webpage.
This is what I have in my html document. How can I get the 'data-srt' (a local file) contents?
Thanks
<div id='srt'
class="srt"
data-video="video"
data-srt="sample.srt" />
</div>
EDIT
$(function()
{
$.get($("#srt").data("srt"), function(text) {
alert(text);
});
});
</script>
I tried the above editied version but instead of displaying the subtitle text it gives me:
[object XMLDocument]