YAMJ / yamj-v2

Yet Another Movie Jukebox (YAMJ) v2
GNU General Public License v3.0
28 stars 11 forks source link

Create a master list of all movies/shows (no trailers) #244

Closed Omertron closed 9 years ago

Omertron commented 9 years ago

Original issue 244 created by Omertron on 2008-10-24T15:20:39.000Z:

What: A simply text list of all movies in a users collection

Why: It will allow skins to scroll through the movie listings without loading any pages.

Description:

I'm pretty sure you guys have seen & been using the movie-flow and trying to adapt it for use in YAMJ.

I was hoping we could adapt atleast one part of it for use right now. The master list.

Movie-flow creates a JS file thats a master list of all the movies in the jukebox. It also creates a file listing each movie in each letter, and genre...but i'll be quite happy with a master list for now.

This list would allow skins like the robinsjexcal (and any future ones) to call upon this list and be able to scroll through movies without actually loading pages up untill they select a movie.

Specific example

In the robinsjexcal skin, on the details page the left bar has 3 movies. The middle one is the current movie shown...the top one is the previous movie, and the bottom is the next movie. With the current setup you have to select and load either the previous or next movie in order to move the list. If we had a master list (.js) file like movie-flow, then they could simply scroll up or down through the movies without loading any of the pages.

I will post a example of one of the .js files when i get home from work.

Omertron commented 9 years ago

Comment #1 originally posted by Omertron on 2008-10-24T18:42:46.000Z:

Please specify the format of the file that you want to use.

Omertron commented 9 years ago

Comment #2 originally posted by Omertron on 2008-10-25T01:50:44.000Z:

Well in the movie-flow it uses a .js file.

Here is the contents of the master list. (it also makes a similar list for each genre and letter)

sorry ahead of time for the long post... here is the complete contents of the master list. (selall.js) From this list he uses his java code to scroll thru selections without loading up pages. If you'd like to see a

function selall(){ total=76; title=["10,000 BC", "300", "310 To Yuma", "Anchorman", "Arrested Development Season 1", "Arrested Development Season 2", "Arrested Development Season 3", "Baby Mama", "Batman Begins", "Be Kind Rewind", "Charlie Wilson's War", "Cloverfield", "College", "Dave Chappelle", "Dexter Season 1", "Dexter Season 2", "Dexter Season 3", "Dexter Season 3", "Drillbit taylor", "Eddie", "Eddie Murphy", "Entourage Season 5", "FORGETTING SARAH MARSHALL", "Fringe Season 1", "Glenngary glen ross", "Hancock", "Harold and kumar escape from guantanamo bay", "Hellboy 2", "Hero", "I Now Pronounce You Chuck And Larry mahek", "Into The Blue", "Its Always Sunny in Philadelphia Season 1", "Its Always Sunny in Philadelphia Season 2", "Its Always Sunny in Philadelphia Season 3", "Its Always Sunny in Philadelphia Season 4", "Juno", "Kungfu panda", "Lost Season 4", "P 21", "Pablo francisco", "Paul Mooney", "Reno 911 Miami UNRATED", "Richard Pryor Here and Now", "RichardPryor", "S ironman", "Scarface", "Semi pro", "Sex And The City The Movie", "Step brothers", "Street Kings", "Superbad", "The Bankjob", "The Bourne Ultimatium", "The Da Vinci Code", "The Dark Knight", "The forbidden kingdom", "The Happening", "The Hills Season 4", "The Incredible Hulk", "The Kingdom", "The love guru", "The Mummy 3", "The Office Season 4", "The Office Season 5", "The persuit of happyness", "The bourne identity", "The bourne supremacy", "The Crow", "The Departed", "The Prestige", "Transformers", "Wall street", "Wanted", "What happens in vegas", "You Don't Mess with the Zohan", "Young People Fucking"]; subs=[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75]; url=[1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76]; title[76] = "There are No Movies for this Selection"; subs[76] = 76; url[76] = 999999; jmplet[1]=3; jmplet[2]=7; jmplet[3]=10; jmplet[4]=13; jmplet[5]=19; jmplet[6]=22; jmplet[7]=24; jmplet[8]=25; jmplet[9]=29; jmplet[10]=35; jmplet[11]=36; jmplet[12]=37; jmplet[13]=38; jmplet[14]=38; jmplet[15]=38; jmplet[16]=38; jmplet[17]=41; jmplet[18]=41; jmplet[19]=44; jmplet[20]=51; jmplet[21]=71; jmplet[22]=71; jmplet[23]=71; jmplet[24]=74; jmplet[25]=74; jmplet[26]=75; }

Each genre file seems to just use numbers based off this main list. For instance the Action.js file only contains a list of numbers...based on their position in this main list.

I can attach the actual files if needed.

Omertron commented 9 years ago

Comment #3 originally posted by Omertron on 2008-10-25T01:52:30.000Z:

I should say...i'm not saying we can't stray from this...ultimately the idea remains the same....its just that if we look to use this setup, we can always borrow and expand upon michaelt's code work he's using in movie-flow already. He's always said he's fine with people doing that as long as they credit him for it.

Omertron commented 9 years ago

Comment #4 originally posted by Omertron on 2008-10-25T15:36:05.000Z:

Does it need to be a java script file (.js) or will xml do?

Omertron commented 9 years ago

Comment #5 originally posted by Omertron on 2008-10-26T05:59:55.000Z:

thats a good question....as far as movie-flow goes...it relies on a java script file.

However, i'm not entirely sure you can't accomplish the same thing from a xml file. I'll have to do some research and testing to determine that.

I think coding wise as long as a movie can identify itself in the list...and then search out other movies in the list it should work.

Omertron commented 9 years ago

Comment #6 originally posted by Omertron on 2008-10-26T07:22:13.000Z:

Is the "cleaned" movie name sufficient? Or do you want the physical filename or something else?

Omertron commented 9 years ago

Comment #7 originally posted by Omertron on 2008-10-26T14:21:01.000Z:

Hmmm, i'm not sure the answer to that either. I'll try to run some tests with some custom created files and get back to you :)

Omertron commented 9 years ago

Comment #8 originally posted by Omertron on 2008-10-29T17:11:33.000Z:

Update: I don't have a full answer for you yet, but i'm getting closer, the only way i've come up using it so far is gonna be as a javascript file, because i need to declare them a variable or an array, then call upon them with javascript functions.

Though as i type that, i just had the idea that if its in XML format and each one is given a part # or something, i might be able to use javascript to dynamicly change the part numbers in the list. But I don't know if/how that would work yet.

I do know that if i can get them listed as a javascript variable it'll work.

Either way though i think i'm going to need the physical filename. Since thats how the htmls, images, and xml files are formated. If we stick with that name it'll make it easier to use the list.

For instance if my file is batman720p.avi batman720p.html batman720p.jpg batman720p.fanart.jpg

Then if i can pull the value batman720p outta the list i should be able to add what ever extension or addition to that i want staticly. If i want the fanart, its just moviename.fanart.jpg etc etc.

Tho if anyone manually over-rides that naming format for images or something its not gonna work...hmm

Its probably more complicated for you, but one solution to that would be to make the list contain all associated files with each movie...html, jpg, small, large, fanart, xml. Then the javascript can split it and it can be used to pull the real value regardless of naming...even if its different from movie to movie.

Is it anymore difficult to add all the files associated to each movie in this list then it is to say just add the filename (without extension preferably)?

Anyways, just wanted to update where i was at with the testing.... :)

Omertron commented 9 years ago

Comment #9 originally posted by Omertron on 2008-10-30T07:26:53.000Z:

It should be reasonably easy to write any of the fields that are in the current XML to another file as part of the post processing run (when it says "indexing libraries")

All I need is the format that you want it in so it can be written out

Omertron commented 9 years ago

Comment #10 originally posted by Omertron on 2008-10-30T20:19:22.000Z:

We should do this in a flexible way. Add a property (mjb.includeMoviesInCategories) that says to include movies in the categories.xml file. We already have a property (mjb.fullMovieInfoInIndexes) to determine how much movie detail in included in the index files (which should apply to the categories file).
Then the categories.xsl translator can take care of formatting the Categories.html as needed by the skin. I've already checked that the extension doesn't have to be .js if the contents is javascript code.

works just fine
Omertron commented 9 years ago

Comment #11 originally posted by Omertron on 2008-10-31T14:35:17.000Z:

Ok, the only part of that i didn't follow was what would be contained in the categories.html file.

Or are you saying that the file created be a html file (named categories.html in this example) and then we can add what ever we want inside? Including the list of movies as a javascript variable?

With this setup would there be a html file for say each genre, each letter, and then one for that has a master list of everything?

Or is it one html file called categories.html that has each of those lists as a variable inside of it?

Omertron commented 9 years ago

Comment #12 originally posted by Omertron on 2008-10-31T20:10:50.000Z:

I was thinking that there would be a property that you could enable that would generate the masterlist.xml file. In that file would be a list of full path filenames (or whatever). You could then do with that file what you wanted.

Omertron commented 9 years ago

Comment #13 originally posted by Omertron on 2008-11-01T01:24:46.000Z:

The exact contents and format of the Categories.html would be under control each skin's categories.xsl file. But the format and content of the Categories.xml must be well defined. It'll look a lot like the current Categories.xml file, but if mjb.mjb.includeMoviesInCategories=true entries would be added for each movie (with full details if mjb.fullMovieInfoInIndexes=true). Additionally, each index in each category include a the numbers of each movie in the index.

I've actually implemented some of this as part of a new skin I've been working on. I've attached a sample Categories.xml, categories.xsl, and generated Categories.html

Omertron commented 9 years ago

Comment #14 originally posted by Omertron on 2008-11-08T13:56:25.000Z:

Is this sufficient to solve this issue?

Omertron commented 9 years ago

Comment #15 originally posted by Omertron on 2008-11-09T14:49:22.000Z:

To be honest i've been so busy lately i haven't gotten a chance to even look at it. I'll try to test it out today or tommorow (hopefully) though.

Omertron commented 9 years ago

Comment #16 originally posted by Omertron on 2008-11-22T18:27:00.000Z:

I haven't gotten it fully functional the way i intended to use it yet, but i did finally get around to looking at gfb107's files.

And wether or not i use the exact same categories.xsl file or not seems as if it doesn't matter...unless i'm missing something. But the information he's gathering in that file is basicly exactly what i'm looking for. I intend to use it in a slightly different format i think (mostly because i don't completely understand how to use his lol). But all the information i want/need is in his file, so i think it would be fine to go ahead with his method.

As long as the image files always continue to use the basefilename for creation, it'll have all the information i need.

Omertron commented 9 years ago

Comment #17 originally posted by Omertron on 2008-11-23T07:59:06.000Z:

<empty>

Omertron commented 9 years ago

Comment #18 originally posted by Omertron on 2008-12-01T12:51:49.000Z:

<empty>

Omertron commented 9 years ago

Comment #19 originally posted by Omertron on 2008-12-09T14:51:45.000Z:

I've committed the changes for including movies in Categories.xml (set mjb.includeMoviesInCategories=true in skin.properties), so that Categories.xml will include movies. If you use this to create Categories.html as a javascript file, you should also put in categories.xsl

As a side note, I've also comitted a change that allows use of the Saxon-B XSL 2.0 translator so that an xsl file can produce multiple files (e.g both an .html and a .js). See issue 310

Omertron commented 9 years ago

Comment #20 originally posted by Omertron on 2008-12-09T14:53:02.000Z:

I've committed the changes for including movies in Categories.xml (set mjb.includeMoviesInCategories=true in skin.properties), so that Categories.xml will include movies. If you use this to create Categories.html as a javascript file, you should also put in categories.xsl

As a side note, I've also comitted a change that allows use of the Saxon-B XSL 2.0 translator so that an xsl file can produce multiple files (e.g both an .html and a .js). See issue 310