Kodi Community Forum

Full Version: [HOW TO] Library Node Examples
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
These should work.

As requested

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<node order="2" type="filter" visible="True">
       <label>Kids Series</label>
       <icon>DefaultTVShows.png</icon>
       <content>tvshows</content>
       <match>all</match>
           <rule field="path" operator="contains">
               <value>mnt/nfs/media/tv/kids</value>
           </rule>
       <limit>20</limit>
       <order direction="descending">dateadded</order>
</node>

or bit more general

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<node order="2" type="filter" visible="True">
       <label>Kids Series</label>
       <icon>DefaultTVShows.png</icon>
       <content>tvshows</content>
       <match>all</match>
           <rule field="path" operator="contains">
               <value>tv/kids</value>
           </rule>
      <limit>20</limit>
      <order direction="descending">dateadded</order>
</node>

even more general

<node order="2" type="filter" visible="True">
       <label>Kids Series</label>
       <icon>DefaultTVShows.png</icon>
       <content>tvshows</content>
       <match>all</match>
           <rule field="path" operator="contains">
               <value>kids</value>
           </rule>
       <limit>20</limit>
       <order direction="descending">dateadded</order>
</node>

And for Movies

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<node order="2" type="filter" visible="True">
       <label>Kids Movies</label>
       <icon>DefaultMovies.png</icon>
       <content>movies</content>
       <match>all</match>
           <rule field="path" operator="contains">
               <value>kids</value>
           </rule>
       <limit>20</limit>
       <order direction="descending">dateadded</order>
</node>

Hope that helps
Cheers.
(2018-06-25, 15:57)LongMan Wrote: [ -> ]These should work.

As requested

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<node order="2" type="filter" visible="True">
       <label>Kids Series</label>
       <icon>DefaultTVShows.png</icon>
       <content>tvshows</content>
       <match>all</match>
           <rule field="path" operator="contains">
               <value>mnt/nfs/media/tv/kids</value>
           </rule>
       <limit>20</limit>
       <order direction="descending">dateadded</order>
</node>

or bit more general

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<node order="2" type="filter" visible="True">
       <label>Kids Series</label>
       <icon>DefaultTVShows.png</icon>
       <content>tvshows</content>
       <match>all</match>
           <rule field="path" operator="contains">
               <value>tv/kids</value>
           </rule>
      <limit>20</limit>
      <order direction="descending">dateadded</order>
</node>

even more general

<node order="2" type="filter" visible="True">
       <label>Kids Series</label>
       <icon>DefaultTVShows.png</icon>
       <content>tvshows</content>
       <match>all</match>
           <rule field="path" operator="contains">
               <value>kids</value>
           </rule>
       <limit>20</limit>
       <order direction="descending">dateadded</order>
</node>

And for Movies

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<node order="2" type="filter" visible="True">
       <label>Kids Movies</label>
       <icon>DefaultMovies.png</icon>
       <content>movies</content>
       <match>all</match>
           <rule field="path" operator="contains">
               <value>kids</value>
           </rule>
       <limit>20</limit>
       <order direction="descending">dateadded</order>
</node>

Hope that helps
Cheers.
 Thanks for the help LongMan, much appreciated!
@teriyaki

No need to quote a full 60+ line post when you are the first to reply, and with just 7 words. Keep the forum neat and clean, please. Smile
I'm trying to separate my Concerts from the rest of my movies. I think I have followed the video examples here (and the concert wiki) but I don't believe it works as I expected.

I have two sources: //server/movies and //server/concerts.

On the main menu <<Movies>, I have a 'Concerts' Category (I assume a Category is a node?) and it correctly shows the 74 concerts when I enter the category. There is another category 'Title" that when I enter on it I see the 55 movies (no Concerts) and the menu name is 'Movies/Title'. That seems to be working as I thought.

However, when I enter on <<Movies>>, the menu is 'Movies/Title' but it shows both Movies and Concerts (152/152).

In Userdata/library/video/movies the two files that were changed:

concerts.xml:
Quote:<?xml version='1.0' encoding='UTF-8'?>
<node order="10" type="filter">
    <label>Concerts</label>
    <icon>DefaultMovieTitle.png</icon>
    <content>movies</content>
    <rule field="path" operator="contains">
        <value>Concerts</value>
    </rule>
</node>

titles.xml:
Quote:<?xml version='1.0' encoding='UTF-8'?>
<node order="50" type="filter">
    <label>369</label>
    <icon>DefaultMovieTitle.png</icon>
    <content>movies</content>
    <match>all</match>
    <order direction="ascending">sorttitle</order>
    <rule field="path" operator="contains">
        <value>movies/</value>
    </rule>
</node>

So my expectation is when I enter the main menu <<Movies>> I should only see //server/movies content and not //server/concerts.
DO I understand this correctly and if so, would someone please help me identify what I did wrong?

Thanks.
@Karellen

Thanks, I'll go through it tomorrow.
\Kodi\userdata\library\video\movies\
make a folder movies a-z
make index.xml
<?xml version='1.0' encoding='UTF-8'?>
<node order="5 A" type="folder" visible="Library.HasContent(Movies)">
 <label>Movies A - Z</label>
 <icon>AZ.png</icon>
 </node>

then you need to make the nodes for sorting the movies
a.xml
<?xml version='1.0' encoding='UTF-8'?> 
<node order="1" type="filter">
 <icon>a.png</icon>
<label>A</label> 
 <name>a</name>
<content>movies</content> 
<match>one</match>
<rule field="originaltitle" operator="startswith"> 
<value>a</value>
 <rule field="originaltitle" operator="startswith">
        <value>THE A</value>
    </rule>
</rule> 
</node> 
https://nofile.io/f/8sOefnMr0MF/a-z+movies.zip
@zozian 

Please stop editing your postings to add advertisement links. If that will happen again, you might get banned from our forums.

Thanks.
Please ban him, he's a spammer and no useful post.
I have DLNA server On KODI 17.6 with tuned media library and DLNA client on Smart Android TV with KODI 16.1
What is the best way to get  information(art/structure etc) from already tuned library ?

Is there any way to use remote media db for KODI on Tv ?

Should i make new library on TV and use DLNA as source? 
Or may be SMB source is better?
Need some help.. I'm trying to modify recentlyaddedmovies.xml to exclude movies marked as watched. I previously modded it to exclude documentaries (which works fine). Based on what I've read, the following should show recently added movies that are not documentaries and have no been watched yet - but it doesn't. Help please!
Code:
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<node order="1" type="folder">
        <label>20382</label>
        <icon>DefaultRecentlyAddedMovies.png</icon>
        <path>videodb://recentlyaddedmovies/</path>
        <match>all</match>
        <rule field="genre" operator="doesnotcontain">
                <value>Documentary</value>
        </rule>
        <rule field="playcount" operator="is">
                <value>0</value>
        </rule>
        <order direction="descending">dateadded</order>

</node>
I seem to remember playcount being a funny one, have you tried setting a condition to check not null instead of a zero? Not sure if that works or not.
Or try less than 1 for play count.
I did try playcount-lessthan-1 but haven't tried check playcount-is-null. What's weird is looking in kodi source, sometimes it resets to -1 and other times to 0. What's the point in playcount ever being -1? But in either case, playcount-lessthan-1 *should* work, but doesn't.

I can see in the log that setting an item to Watched sets "playcount":1 and setting it to Unwatched sets it to "playcount":0. Maybe there's a bug here?
Depending on how confident with IT stuff you are, you could perhaps try using an sql browser to see what the database holds for play count when an item hasn’t been played.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21