• gslweb

    (@bloodytom)


    I can’t make captions work on JW player. I added the shortcode attribute player_captions and the player doesn’t load anymore. The code now goes like this:

    [s2Stream player="jwplayer-v6" player_path="/jwplayer/jwplayer.js" player_width="900" player_height="506" file_download="video.mp4" player_captions="file:'/captions/video-en.srt',label:'English'"/]

    The video is hosted on AWS and the caption is hosted on my server.

    The player/video works if the player_captions attribute is removed. The player doesn’t load at all when the attribute is there.

    I also tried manually integrating the jwplayer to s2member using the following code:

    jwplayer("myElement").setup({
    			playlist: [{
    				file: '<?php echo $mp4["url"]; ?>',
    				tracks: [{
    					file: "/captions/caption-en.srt",
    					label: "English",
    					kind: "captions",
    					"default": true
    				},
    					{
    					file: "/captions/caption-fr.srt",
    					label: "French",
    					kind: "captions",
    				}]
    			}],
    			primary: 'flash', width: 900, height: 506
    		});

    The video plays and the CC option is enabled and I can choose English or French but no caption is displayed on the player.

    Thanks in advance for your help.

    https://www.ads-software.com/plugins/s2member/

  • The topic ‘How to Make Captions Work on JWPlayer’ is closed to new replies.