20 Nov 2019 - TVDB Scraper v3.2.0 is now available which reinstates scraping. TVDB are still in the process of fixing a number of bugs so there may still be further breakages. See this post. 2901570 (post)

Variable for labeling question
#1
i am currently using:

    <!--Video Resolution Label-->
    <variable name="PlayerVideoResolution">
    <value condition="String.IsEqual(VideoPlayer.VideoResolution,1080)">1080P</value>
    <value condition="[String.Contains(Player.Filenameandpath,.HDR.) + String.IsEqual(VideoPlayer.VideoResolution,4K)]">4K HDR10</value>
    <!--value condition="[String.Contains(Player.Filenameandpath,.HDR10+.) + String.IsEqual(VideoPlayer.VideoResolution,4K)]">4K HDR10+</value-->
    <value>$INFO[VideoPlayer.VideoResolution]</value>
    </variable>

to set the resolution label in the VideoFullScreen.xml, i am trying to add a label for 4K HDR10+, see the commented out value above in red. in the current form above, 1080P and HDR10 work perfectly, but if i uncomment the HDR10+ line both HDR10 and HDR10+ stop working and just display 4K.

is it possible to have both in a single variable? is my syntax incorrect?
Reply
#2
I could be wrong but I think you can't use some special characters like the "+" sign for the string inside the xml tag directly, did you try escaping the "+"?
Instead of "+" try with "& #43;" without the the space between "& #" and without the double quotes or "&plus;" without the double quotes.
Useful info

EDIT: if those are local files, you might be better of renaming them and exclude the + sign to something like this  ".HDR10plus."
Reply
#3
the problem is indeed the +.

when evaluating a condition, kodi searches the condition for + and | characters.
a + is considered a 'logical and'.
a | is considered a 'logical or'.

there should be an error in your log indicating kodi can't parse that condition.
afaik there is no workaround for this..
Do not PM or e-mail Team-Kodi members directly asking for support.
Always read the Forum rules, Kodi online-manual, FAQ, Help and Search the forum before posting.
Reply
#4
(2019-10-24, 23:59)vitorp07 Wrote: I could be wrong but I think you can't use some special characters like the "+" sign for the string inside the xml tag directly, did you try escaping the "+"?
Instead of "+" try with "& #43;" without the the space between "& #" and without the double quotes or "&plus;" without the double quotes.
Useful info

EDIT: if those are local files, you might be better of renaming them and exclude the + sign to something like this  ".HDR10plus."

i ended up using this: HDR10plus
Reply
 
Thread Rating:
  • 0 Vote(s) - 0 Average



Logout Mark Read Team Forum Stats Members Help
Variable for labeling question00