Lightbox link

this was a private reply with post_id 62312

I think it maybe related to the creation of the thumbnail as afyer that the videos don't play in the lightbox anymore

Hi Ritesh

OK I have narrowed it down to the code.

If I use

jQuery('.media-type-video .rtmedia-item-thumbnail').each( function(){ jQuery(this).wrap(''); }); jQuery('.media-type-video').click(function(){ jQuery(this).find('video').each(function(){ $('video')[0].player.pause(); }); });

Then the video will load and play in the lightbox - but the page video plays until you click the lightbox player.

If we can get the page video to not play and the lightbox video to autoplay the solution is fantastic

Thanks again Danny

OK my last word on this as a clue hopefully for you. It seems your code works until the thumbnail is created and then it breaks. ( I think !! :-) )

Once it breaks if I delete the line with .player.pause then the video loads and plays in the lightbox but the page video plays until you click the lightbox. This is how

http://sharingdevsites.info/ssrebuild/stories/ is currently set

Ideally If we can get the page video to not play and the lightbox video to autoplay the solution is fantastic

Thanks again Danny

Hi

I've just realised why it doesn't work the player is in pause. If you pause the video on the page then go to the lightbox then the video just doesn't load it'as paused. So we can't use .player.pause that way it seems in the exisitng setup

Danny :-)

Hi do you have anymore ideas on the issue? using player.pause is not going to work it seems any other workaround you can think of

Many Thanks Danny

Hi Danny, I checked this link -> http://sharingdevsites.info/ssrebuild/stories/ and checked the first video. But it isn't exist. Please try uploading new video and check. The solution I gave you is working perfectly fine on my end.

Hi Ritesh

http://siteshackdevsites.info/ssrebuild/stories/

Couple of new Videos loaded. Can you check for me. My end the video on the page does not play which is great but the problem is that my end the video never loads in the lightbox. When you say The solution I gave you is working perfectly fine on my end. do you mean on my site or on your test site?

Thanks

Danny

Hi Ritesh

It all seems to work now which is great and many thanks :-)

I have just one problem and that is with larger videos that take time to load. Not sure how the load happens but if it is fully loaded on the page it still in some cases wants to reload in the lightbox and or the buffering is not as effective as on the page. Where as on the page it will play while buffering in the lightbox its seems to need more in the buffer. Can this be altered any way. I am concerned with people who don't have the quickest of adsl

Thanks Danny

Would it be possible to make the lightbox have a URL which would allow people to link to it, just like Facebook does? If so could you help me with that?

Thanks, Liutauras.