(2019-03-05, 13:56)sualfred Wrote: [ -> ]It is possible, I use it a lot in Embuary. Especially for my "pseudo Globalsearch" integration, which is basically the same output of Globalsearch but only based on the skin engine and xsp paths. You just have to be sure to use the url encoded format.
Example:
Code:
<variable name="Local.SearchMovies">
<value condition="!String.IsEmpty(Skin.String(CustomSearchTerm)) + Library.HasContent(movies)">videodb://movies/titles/?xsp=%7B%22order%22%3A%7B%22direction%22%3A%22ascending%22%2C%22ignorefolders%22%3A0%2C%22method%22%3A%22sorttitle%22%7D%2C%22rules%22%3A%7B%22and%22%3A%5B%7B%22field%22%3A%22title%22%2C%22operator%22%3A%22contains%22%2C%22value%22%3A%5B%22$INFO[Skin.String(CustomSearchTerm)]%22%5D%7D%5D%7D%2C%22type%22%3A%22movies%22%7D</value>
</variable>
<variable name="Local.SearchActorMovies">
<value condition="!String.IsEmpty(Skin.String(CustomSearchTerm)) + Library.HasContent(movies)">videodb://movies/titles/?xsp=%7b%22rules%22%3a%7b%22and%22%3a%5b%7b%22field%22%3a%22actor%22%2c%22operator%22%3a%22is%22%2c%22value%22%3a%5b%22$INFO[Skin.String(CustomSearchTerm)]%22%5d%7d%5d%7d%2c%22type%22%3a%22movies%22%7d</value>
</variable>
Did I undertand this correctly? One can basically create a custom playlist direclty in a <Content> Tag.
I currently use some Playlists to provide the content for some of my widgets, but with this I could remove the playlists completely right?
It's basically the same, yes. Only with just a few tiny little differences. I cannot remember what, but I've found at least on thing what wasn't possible via path but with smartplaylists.
If you want it easy -> create own custom nodes via the Video Node Editor -> Open the newly created node (not in the addon) -> use the generated xsp path you get via $INFO[Container.Folderpath]
Edit:
And bookmark this site
https://www.urlencoder.org/
ah great, I will give it a try
(2019-03-06, 06:10)jurialmunkey Wrote: [ -> ]Proof of concept:
Here's local video info being called from videoinfo dialog for movies in the set. This is done entirely with the skinning engine and local content. There is even a breadrcrumb memory so that you can backtrack.
Amazing. Looks perfect.
I may have to borrow that idea for madnox 2.0
@
sualfred - do you know if there is a way to use an OR operator of some kind?
For instance, I'm trying to make a list where genre contains Action OR Adventure. Combining multiple content paths means you get duplicates if a movie has both genres (plus you can't combine sorting across both paths).
You can combine and + or via JSON so I guess that's also possible for xsp paths. But to remove the duplicates you have to cleanup that list afterwards. Via Python it's easy.
FYI: Untested combination of "and" + "or" in xsp
videodb://movies/titles/?xsp={"rules":{"and":[{"or":[{"operator":"is","field":"genre","value":["Action"]},{"operator":"is","field":"genre",["Adventure"]}]},{"operator":"isnot","field":"title","value":"Alien"}]},"type":"movies"}
edit2: doesn't work for xsp
Edit:
Why don't you use this? This doesn't return any duplicate.
Code:
videodb://movies/titles/?xsp={"rules":{"or":[{"field":"genre","operator":"is","value":["Action"]},{"field":"genre","operator":"is","value":["Thriller"]}]},"type":"movies"}
Edit3:
What exactly do you want to achieve? A "similar movies" widget based on a listitem?
(2019-03-08, 07:34)sualfred Wrote: [ -> ]You can combine and + or via JSON so I guess that's also possible for xsp paths. But to remove the duplicates you have to cleanup that list afterwards. Via Python it's easy.
FYI: Untested combination of "and" + "or" in xsp
videodb://movies/titles/?xsp={"rules":{"and":[{"or":[{"operator":"is","field":"genre","value":["Action"]},{"operator":"is","field":"genre",["Adventure"]}]},{"operator":"isnot","field":"title","value":"Alien"}]},"type":"movies"}
edit2: doesn't work for xsp
Edit:
Why don't you use this? This doesn't return any duplicate.
Code:
videodb://movies/titles/?xsp={"rules":{"or":[{"field":"genre","operator":"is","value":["Action"]},{"field":"genre","operator":"is","value":["Thriller"]}]},"type":"movies"}
Edit3:
What exactly do you want to achieve? A "similar movies" widget based on a listitem?
I'll give these a go when I get home. Thanks.
Yeah, a similar movies widget without an addon/plugin.
Also trying to do a movies starring cast members - i.e. If a movie has one of the first few in cast list 50.
@
jurialmunkey
You mean like this?
-> "directed by" splits all possible directors and returns their movies
-> "more like this" is based on listitem.genre, but just picks 2 random values of it (action + thriller, but not drama for example) and returns a valid set of items without the movie that was used for the request
It wasn't 100% possible with xsp. That was one of the main reasons for script.embuary.helper (and because skin helper service is so slow and bugged)
Maybe I really should consider to release my stuff to the repo so others can benefit too....
@
sualfred - almost! Say I'm looking at Aliens info - I want to get a list of movies that star Sigourney Weaver OR Michael Beihn OR Paul Reiser OR Bill Paxton.
I can get actor names from cast list using listitemabsolute, but I need an OR operator for "actor is"
That will work with the xsp from above but it will also include "Aliens", because xsp doesn't support a mix of AND and OR.
Great! Basically what I do
Love to see those things on other skins, too. It gives you endless options of cross-linking those results in all possible windows and call actions.
(2019-03-13, 09:15)jurialmunkey Wrote: [ -> ]@sualfred - Your idea about replacing globalsearch with library paths inspired me to make something similar. Basically it's an adaptive search which not only displays lists of movies/tvshows/episodes/artists/albums with matching titles, but it shows lists of movies/tvshows that search by genre, actor, director, studio, country, and year. So you can just search by genre by typing a genre as the search term, or by year by typing a year, or actor by typing an actor and so on. It also provides a list of youtube videos matching the search term.
Thanks so much for the inspiration and help with these node paths.
I've wanted something like this for ages and now I can finally achieve it, and in such a simple fashion too!
Sounds amazing, I would like to integrate something similar. would you mind sharing code?
(2019-03-13, 13:20)cartman.dos Wrote: [ -> ] (2019-03-13, 09:15)jurialmunkey Wrote: [ -> ]@sualfred - Your idea about replacing globalsearch with library paths inspired me to make something similar. Basically it's an adaptive search which not only displays lists of movies/tvshows/episodes/artists/albums with matching titles, but it shows lists of movies/tvshows that search by genre, actor, director, studio, country, and year. So you can just search by genre by typing a genre as the search term, or by year by typing a year, or actor by typing an actor and so on. It also provides a list of youtube videos matching the search term.
Thanks so much for the inspiration and help with these node paths.
I've wanted something like this for ages and now I can finally achieve it, and in such a simple fashion too!
Sounds amazing, I would like to integrate something similar. would you mind sharing code?
I'll share it once I get home. But it's pretty simple - just a custom window with a grouplist of lists with content paths and using a skinstring as the search term.
If you call the window like
<onclick>skin.setstring(foobar)</onclick>
<onclick>activatewindow(1135)</onclick>
Kodi will call the keyboard dialog to set the foobar skinstring and it won't open the custom window with the search lists until after the keyboard closes.