Correct Playlist Format
#1
Which of the following playlists is the correct format:
Code:
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<smartplaylist type="movies">
    <name>12</name>
    <match>all</match>
    <rule field="mpaarating" operator="is">
        <value>UK:12</value>
        <value>UK:12A</value>
    </rule>
    <order direction="ascending">title</order>
</smartplaylist>
or
Code:
<smartplaylist type="movies">
    <name>12</name>
    <match>all</match>
    <rule field="mpaarating" operator="is">
        <value>UK:12</value>

    </rule>
    <rule field="mpaarating" operator="is">
        <value>UK:12A</value>
    </rule>
    <order direction="ascending">title</order>
</smartplaylist>
Reply
#2
Can anyone help guide which one of the above is correct?
Reply
#3
Whatever works best for you, but from my point of view it's always better to have multiple rules, so the second would work fine, but it does look like you're asking for an impossible task, in that the file must meet '12' and '12A' not one or the other. also most scripts start with <?xml version="1.0" encoding="UTF-8" standalone="yes" ?> and in your second example you didn't include it. I'm certainly no expert in playlist authoring, but I've seen over time, rules get added and subtracted and the way they work has changed in some cases. Smart playlists (wiki) https://seo-michael.co.uk/how-to-create-...xbmc-kodi/ For the main I would say stay inside the Kodi playlist editor, and try different things, If you get stuck, post again.
Reply
#4
Cheers PatK

So essentially either might/will work, and a matter of trial and error?
Reply
#5
I don't think either will work (In fact I tried them both)

This code works... (tested it) sorry for using 14 instead of 12, but it brought many more films. Looks like the letter A brings nothing or didn't work, along with the inclusion of the 'UK:' (I guess it's looking for only a numerical value) Best to use the Kodi editor for this.

<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<smartplaylist type="movies">
<name>Test2</name>
<match>one</match>
<rule field="mpaarating" operator="contains">
<value>14</value>
</rule>
<order direction="ascending">title</order>
</smartplaylist>
Reply
#6
Interesting...

I know that if i want to group a selection of my movies based on their MPAA rating, i can via the smart playlist rules. I have therefore done that and when the scrapers have returned said MPAA rating, the movies have been grouped accordingly. EXCEPT in instances where the rating is ambiguous (e.g. 12 v 12A).

However, and hence my thread, the UK have some odd classifications and the scrapers picked these up; i.e. picks up 12A instead of 12. Therefore I'm trying to classify all of these as 12 via the smart playlist route, as Kodi still won't recognise parental controls in their development and offer up a better solution.

Therefore how do I group via smart playlist 12A and 12 together, I am assuming it can only be one or the other or maybe both work in the examples I have provided.
Reply
#7
(2015-06-21, 01:31)Hairy Hippy Wrote: ... how do I group via smart playlist 12A and 12 together, I am assuming it can only be one or the other or maybe both work in the examples I have provided.
The problem I see is your use of '<match>all</match>' - Pat K already identified that.
The only films that will show up in those playlists are ones that are rated 12 and 12A.
You need to select 'items must match one or more of the rules' when you make the playlist.
eg

Quote:<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<smartplaylist type="movies">
<name>12</name>
<match>one</match>
<rule field="mpaarating" operator="is">
<value>12</value>
</rule>
<rule field="mpaarating" operator="is">
<value>12A</value>
</rule>
</smartplaylist>
Reply
#8
Once you get a rule with the filter that works satisfactorily for one, the trick would be to create more playlists with further rules and then combine them with a playlist that uses the playlist rule..
Reply
#9
Thanks both. It's the one v all match that was required but can it be grouped rather than two times rule field or only in the format troggy stated?
Reply

Logout Mark Read Team Forum Stats Members Help
Correct Playlist Format0