Jump to content

Recommended Posts

Hi!

 

I've developed HTML5 video player with my own controls. On the right side I have playlist, if I click on <li> element, then new video will be loaded and it starts playing. Everything works fine in Firefox, Chrome, Opera, IE 9 but there is problem in Safari. Well, If I click on <li> element, then new video won't be loaded.

Code is located at http://martleib.com/projektid/elion_html5_videoplayer/ (You can view Source Code)

 

I quess, the problem is somewhere in "js/player.js" in

	$('.video_sidebar .overview li').click(function() {
	var mp4link = $(this).attr('mp4link');
	var webmlink = $(this).attr('webmlink');

	$("#html5-video-tag video")[0].pause();
	$("#html5-video-tag video #mp4").attr("src", mp4link);
	$("#html5-video-tag video #webm").attr("src", webmlink);

	$("#html5-video-tag video")[0].load();
	$("#html5-video-tag video")[0].play();

	$(".video_sidebar .overview li").css("background", "none");
	$(this).css("background-color", "#fff");
});

 

But when you visit link http://martleib.com/projektid/elion_html5_videoplayer/?id=1 (it simulates click on first <li> element in playlist) then video will be loaded and starts.

 

All the best

Mart L.

Link to comment
https://forums.phpfreaks.com/topic/264434-html5-video-load-not-working-in-safari/
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.