Trailer for each Movie

That is correct however the chance of YouTube not having a suitable trailer is slim.


If you think it is better to check for a trailer before exposing the button, that can certainly be done.


After some thought, I might be able to use themoviedb.org to get the YouTube information rather than querying YouTube. This should improve accuracy and be able to give a quick yes/no to a trailer instead of testing the YouTube search results for a lookup success/fail.


I will attempt to change the methodology and report back what I find.

That is correct however the chance of YouTube not having a suitable trailer is slim.

If you think it is better to check for a trailer before exposing the button, that can certainly be done.

After some thought, I might be able to use themoviedb.org to get the YouTube information rather than querying YouTube. This should improve accuracy and be able to give a quick yes/no to a trailer instead of testing the YouTube search results for a lookup success/fail.

I will attempt to change the methodology and report back what I find.


I do that on rarflix, it was a 1% improvement to check tmdb first :)

Good to know it isn’t much! I am wondering if Plex gives themoviedb.org ID or if I need to lookup the TMDB ID first then query for the trailer.


If I need to do two lookups, I might prefer the single lookup from YouTube in light of your 1% statistic :stuck_out_tongue:


Update: @ljunkie, since you have experience with this, do you know if any significant amount of movies that lack trailers on YouTube?

Good to know it isn't much! I am wondering if Plex gives themoviedb.org ID or if I need to lookup the TMDB ID first then query for the trailer.

If I need to do two lookups, I might prefer the single lookup from YouTube in light of your 1% statistic :P


The 1% might just my opinion, but all the tmdb does is link to the youtube video. Many times there will be a youtube trailer, but no one has added it to tmdb or the video linked on tmdb is not even as good as the top search result.

I ended up using tmdb and your tube search together because people really wanted TMDB :)

I ended up querying the tmdb api for the ID. Even if the PMS stores the ID, it's not exposed at an api level.

Nice work btw. Users love this feature!

I added this feature into PlexConnect (not PMS) and uses AJAX to lookup the YouTube trailer ID and uses the YouTube channel to get a proper URL for playback.

I have issued a pull request for this feature, available here: https://github.com/iBaa/PlexConnect/pull/172

Please let me know if this works and/or has any issues.

Thank you.

How do I use/implement this?

The code has been merged into the master branch. All you have to do is update:

git pull
Of course, you have to restart PlexConnect when updating/changing code.

The code has been merged into the master branch. All you have to do is update:

Of course, you have to restart PlexConnect when updating/changing code.

Oh God, are you telling me that I just haven't looked yet? Sweet Jesus, somebody kick me out of here.

nice!! now, just need myplex to work and plexconnect is golden

Just wanna say thanks for implementing this feature! It'll be so useful for my wife and I when we're trying to find a movie to watch.

thats amazing !!

Thank you !!!

WOW, cool!

I just used this the other night and it worked flawlessly.  Thanks for your hard work!

Some feedback/question:


From limited usage of it it works really well but I have noticed that for me it only seems to grab English language trailers.

My setup may be slightly unusual (multi lingual family) but cannot be too much of an edge case.

My ATV language is set to English but I do have a movies section in a specific other language (they are actually English movies dubbed to that language) that has the scanner set for that section to pull in a synopsis in that language, however the trailers pulled from this section still are in English.

Bear in mind that films can often use the English title for a large proportion of films but then for certain other ones will have entirely different titles in that language, their ID (IMBD?) should however still be the same.

Does it only support English language trailers at the moment and if not what triggers the change in language?

That’s something I didn’t even consider.

Let me see what I can find out about different languages and how TMDB handles that and I will get back to you.

That's something I didn't even consider.

Let me see what I can find out about different languages and how TMDB handles that and I will get back to you.


I'd be interested In what you find. I didn't see anything special in tmdb, it just linked trailers to youtube. Of course I didn't look to hard as I didn't think about this issue :/

A really interesting add on. I played with it and is a very good addition. Could not find trailers for old Hindi movies but did well for new ones and Hollywood ones. 

hey salbahra/roidy , just want to let you know that trailer isn't working for shared users on latest commit (408)..thanks for the great work and keep it up. 

@iamjustme You’re right, I assumed localhost when constructing the URL. I will propose a fix very soon.

Thanks!

A liitle off subject and already asked prior but this gives me hope, but since you were able to implement this, is it also possible to get a similar audio intro theme music option in tv shows as well when you are selecting a tv show? If not something like the intro to the season, as in the theme video prior to each family guy episode or something of that nature? Tell me yes, crosses fingers. :slight_smile:


I would love to see a intro like this per season as an option(american horror story asylum season 2):

https://www.google.com/url?sa=t&rct=j&q=american+horror+story+intro+season+2&source=web&cd=1&ved=0CDEQtwIwAA&url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DE00BPNKubKs&ei=sJF0Us-TNZXKsQSvmYHwAw&usg=AFQjCNEOr8Cn8cHw_u248ZpvjncfYyimDQ&sig2=ojVekIlb6xrv_bwBH_SCgw

@iamjustme You're right, I assumed localhost when constructing the URL. I will propose a fix very soon.Thanks!


Great stuff :D