Lightbox link

Slight Issue that the on page video plays under the lightbox so you 2 playing at the same time !! :-)

Use this code for that issue, jQuery('.media-type-video .rtmedia-item-thumbnail').each( function(){ jQuery(this).wrap(''); }); jQuery('.media-type-video').click(function(){ jQuery(this).find('video').each(function() { jQuery(this)[0].player.pause(); }); });

Really great thanks Ritesh. The only thing left is autoplay in lightbox is that acievable

Many many thanks

Danny

Tried adding $("#video_player")[0].autoplay = true;

but didn't work

:-)

Hi Ritesh

Do you have any thoughts on Lightbox autoplay or have I exhausted you :-)

Many thanks

Danny

Hi Ritesh

Sorry got a bit of a problem PLEASE USE THE LATEST VIDEO Jilkminggan Portraits with image of man

The video does not seem to play from lightbox at

http://sharingdevsites.info/ssrebuild/members/lizthompson/ OR

http://sharingdevsites.info/ssrebuild/stories/

But does from lightbox at

http://sharingdevsites.info/ssrebuild/members/lizthompson/media/video/

That is it plays from the media gallery but not the activity pages.

Its definitely something to do with the code as when I take it off then then the video plays straight way in the lightbox when I press play.

/* rt-lightbox-link */

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

Sorry

Thanks

@siteshack, the video in activity stream(id:112) is not the same in the video tab(id:113). They both are different.

Thanks for that - thought I was going mad !!

Last couple of questions

The thumbnails are they automatically generated or do you have to manually apply the FFMPEG generate button after each upload? If so is there an update coming that will auto generate a thumbnail and you can choose between the three if you need to change it?

The autoplay on lightbox select?

Ritesh I can't thank you enough for you help

Danny :-)

No there seems to be a problem. You change the thumbnail and the video doen't play in the activity but does in the media gallery again. Presumably creating the thumbnail alters the id !!

ids are the same actually. Something weird going on!!! The video is just not loading on the activity pages but is on the media gallery pages. The loading bar reflects this as in the media gallery it turns blue

@siteshack, try uploading new video and then check. Regarding FFMPEG, it automatically generates thumbnails.

I TRIED THAT. I'LL TRY AGAIN

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