Playing videos in the JWplayer

Siasb
Siasb
Offline
0
Hi Germi,

My client was wondering if he can play a video in the JWplayer while a song is playing. I figured JWplayer likely only does one action at the time (even though it could be multi-threaded). But maybe my client can have a video that plays the song. Putting it another way, Can the play list have videos as well and not just songs. Thanks.
Responses (11)
  • Accepted Answer

    Thursday, March 11 2010, 04:26 PM - #Permalink
    0
    YES, the playlist can have videos (you just need to click on "add video to playlist") but NO, it cannot play "two things at the same time"... of course...
    The reply is currently minimized Show
  • Accepted Answer

    Siasb
    Siasb
    Offline
    Thursday, March 11 2010, 09:48 PM - #Permalink
    0
    Thank you very much Germi. I didn't noticed that earlier. The videos are added to the play list; however, I don't seem to get a thumbnail for them (Also get the triangle for file not found in the player area). When I hit play it does not play the video. The JWplayer module, I did not update since 2.0 update as I have to reintegrate the modifications for the commercial version. Is the version of module dependent on the component version for the video. Should I be looking at module or elsewhere for it not working. BTW, the video plays fine in the song page. Thanks much.
    The reply is currently minimized Show
  • Accepted Answer

    Siasb
    Siasb
    Offline
    Thursday, May 20 2010, 01:38 PM - #Permalink
    0
    Hi Germi,

    Hope all is well. My client added a video to playlist, and is still having the same issue of not being able to play the video (YouTube). He gets no thumbnail and when we play it, we get the triangle for I presume file not found. The video shows up fine in the song page. The module has since the previous post been updated to the 2.0+ version. If you have any hint in this regard, I would appreciate it.
    The reply is currently minimized Show
  • Accepted Answer

    Siasb
    Siasb
    Offline
    Monday, May 31 2010, 08:16 AM - #Permalink
    0
    Hi Germi,

    I replaced the JWplayer with the one released with MC and it can play the video in the playlist. I still don't get a thumbnail for the video though. But it seems the issue is the changes since the new JWplayer that is not compatible. I need to pin this interface change down to see where I should change in the MC code. I'll check the LongTail forums/docs for further info. If you can add some info on this side, it could help me on the changes. Thanks.
    The reply is currently minimized Show
  • Accepted Answer

    Monday, May 31 2010, 05:35 PM - #Permalink
    0
    mmm but.. did you changed the player version??
    if you did... remember that the "youtube" plugin is an extra file (called yt.swf) that you must update, too!

    in any case... it should work with the native MC version... and about the thumbail: its a thing of the YT plugin... sometimes it does not show it.. :S
    The reply is currently minimized Show
  • Accepted Answer

    Siasb
    Siasb
    Offline
    Monday, May 31 2010, 07:06 PM - #Permalink
    0
    Thank you very much Germi,

    I uploaded the new player.swf (5.1), the associated yt.swf released in the same directory, and SWFObject.js (looks the same [v1.5] but uploaded anyway), and don't see the video. I get the error #2048 and after the search, it might be related to the crossdomain access and crossdomain.xml file. I added the following lines to the main crossdomain.xml file for the site and it did not help:


    LT allow-access-from domain="*.youtube.com" /GT
    LT allow-access-from domain="*.ytimg.com" /GT


    I also put a new crossdomain.xml file in the plugin directory in case the main one is not seen by it, and it does not help either. There is a playlist_functions.js in the plugin directory, could that also be involved? I looked briefly, I have to look closer.

    I'll send an email to longtail developer in this regard, maybe he can point out some info further. I'll post back any new info. I gather.

    Thanks again.
    The reply is currently minimized Show
  • Accepted Answer

    Siasb
    Siasb
    Offline
    Tuesday, June 01 2010, 08:08 AM - #Permalink
    0
    Hi Germi,

    Sorry that I had to work on this on and off. I played with the crossdomain.xml file location a bit more (no result), and looked into the content of the playlist XML file. I found a site:


    http://validator.xspf.org/


    that validates playlists. After checking the playlist with it, I found some errors that I fixed in the name of the images in the album that were using spaces. There are also errors for the link tag that do not have any content, but I don't think the error is there. I still haven't checked with longTail (I will). I wanted to understand the details a bit more before doing so. I also found the issue/solution for the thumb image for videos. The image for videos at youTube can be found at the following address:


    http://img.youtube.com/vi/#####/2.jpg

    Where ##### is the video id.
    For this video id, the video can be found at:

    http://www.youtube.com/v/#####


    So I changed the following code to fix it:


    =========================================================
    website.com/components/com_muscol/views/playlist/view.feed.php
    around line 63
    =========================================================

    else{ // http://www.youtube.com/v/6hzrdeceekc OR 6hzrDeceEKc
    $youtube_video_id = str_replace("http://www.youtube.com/v/", "", $song->video);
    }
    $youtube_video_url = "http://www.youtube.com/v/" . $youtube_video_id ;

    $item->location = $youtube_video_url ;

    if($comp_params->get('loadimagesplayer')) $item->image = $youtube_video_url ;
    $item->annotation = $song->artist_name . " - " . $song->album_name;

    // loads item info into rss array
    $document->addItem( $item );
    =========================================================
    VVVVV Replace with VVVVV
    =========================================================
    else{ // http://www.youtube.com/v/6hzrdeceekc OR 6hzrDeceEKc
    $youtube_video_id = str_replace("http://www.youtube.com/v/", "", $song->video);
    }
    $youtube_video_url = "http://www.youtube.com/v/" . $youtube_video_id ;
    $youtube_video_image_url = "http://img.youtube.com/vi/" . $youtube_video_id . "/2.jpg" ;

    $item->location = $youtube_video_url ;

    if($comp_params->get('loadimagesplayer')) $item->image = $youtube_video_image_url ;
    $item->annotation = $song->artist_name . " - " . $song->album_name;

    // loads item info into rss array
    $document->addItem( $item );
    =========================================================


    I'll report more info. when I have some.
    The reply is currently minimized Show
  • Accepted Answer

    Tuesday, June 01 2010, 03:51 PM - #Permalink
    0
    yes, you're right about the YOUTUBE image. good work!
    hope you can find a definitive solution..

    question: can you give me url of that playlist checker? thanks! it could be very useful
    The reply is currently minimized Show
  • Accepted Answer

    Siasb
    Siasb
    Offline
    Wednesday, June 02 2010, 04:43 PM - #Permalink
    0
    Hi Germi,

    LongTail looked at it (They are also great help), and recognized the issue was using the following format:


    http://www.youtube.com/v/


    Instead of this:

    http://www.youtube.com/watch?v=


    So I changed the code in

    =========================================================
    www.website.com/components/com_muscol/views/playlist/view.feed.php
    line 66
    =========================================================

    From:
    $youtube_video_url = "http://www.youtube.com/v/" . $youtube_video_id ;

    To:
    $youtube_video_url = "http://www.youtube.com/watch?v=" . $youtube_video_id ;


    Now, in the 'if' clause before that line, there is a redundancy for the case of the original string being in the form of watch?v= ,but the 'if' clause still covers all three cases of strings allowable in the input field for the video.

    Also here is the link to the playlist validator site again in code blocks:

    http://validator.xspf.org/
    The reply is currently minimized Show
  • Accepted Answer

    Wednesday, June 02 2010, 04:45 PM - #Permalink
    0
    ok!! so all works fine for you now?

    (yes, longtail support is great, too!)
    The reply is currently minimized Show
  • Accepted Answer

    Siasb
    Siasb
    Offline
    Thursday, June 03 2010, 03:44 PM - #Permalink
    0
    Hi Germi,

    Thanks. The selection and play of both the video and music are working fine now. The issue of item 'type' being video in the list and when deleted, that stays in the database still there. I had to go back and fix the database after my client was done editing. If you can tell me where in the code it is, I can maybe play with it. Thanks again.
    The reply is currently minimized Show
Your Reply