DBID from another container
#1
I'm trying to obtain a dbid from a listitem in another container. This other container is a list of the latest watched videos. I'm trying to pass the dbid into the extended info script to return a list of recommended movies based on the last watched video. I've tried using the following without any success:

Code:
<onclick>ActivateWindow(Videos,plugin://script.extendedinfo?info=similarmovies&amp;&amp;dbid=$INFO[Container(3291).ListItemPosition(1).dbid],return)</onclick>

When I replace the $INFO label with a static DBID (like below), it works fine:

Code:
<onclick>ActivateWindow(Videos,plugin://script.extendedinfo?info=similarmovies&amp;&amp;dbid=123,return)</onclick>

This leads me to believe that there is something wrong with the infolabel I'm using. I've looked on the infolabel wiki page and it states that Container(id).ListItemPosition(id).[infolabel] can be used as follows: Shows the infolabel for an item in a Container. the item id is the position in the container relative to the cursor position. ( eg: Container(50).ListItemPosition(4).Genre )

I've even tried using Container(id).ListItemAbsolute(id).[infolabel]

For information, the container I'm trying to pull the dbid from is a 'dummy' container which I've setup as follows:

Code:
        <control type="list" id="3291" description="MoviesDummy">        
   <visible>false</visible>
   <content limit="10">special://skin/extras/playlists/RecentlyWatchedMovies.xsp</content>
</control>

Ultimately I'd like to use this information in the content tag for a dynamic list, something like this:

Code:
<content limit="10">$INFO[ActivateWindow(Videos,plugin://script.extendedinfo?info=similarmovies&amp;&amp;dbid=$INFO[Container(3291).ListItem(0).DBID],return)]</content>

Again, this content tag works, when I replace the info label.

Any thoughts or suggestions are much appreciated.

Cheers.

~Raze
Reply
#2
You should drop the ActiveWindow stuff from the content tag...

Like this:

<content limit="10" target="video">plugin://script.extendedinfo?info=similarmovies&amp;&amp;dbid=$INFO[Container(3291).ListItem(0).DBID]</content>
Reply
#3
(2016-03-04, 15:16)marcelveldt Wrote: You should drop the ActiveWindow stuff from the content tag...

Like this:

<content limit="10" target="video">plugin://script.extendedinfo?info=similarmovies&amp;&amp;dbid=$INFO[Container(3291).ListItem(0).DBID]</content>

Thanks for the reply marceveldt.

I've done a bit more and the $INFO label works with other lists (even when point their content tag to the same smart playlist noted above), but not the "dummy list" that I've set. So this leads me to believe that the problem is not with the $INFO label or the content (the .xsp) but with my 'dummy list' itself.

I'm going to play around with it a bit later and see if i can pinpoint the problem with the container i'm pointing the $info label at.

In the meantime if you have any thoughts, I'd love to hear them.

Cheers,

~Raze
Reply
#4
It appears the problem was with the dummy list I was trying to point the info tag to. Apparently it has to at least allow hidden focus and needs to contain an <itemlayout> tag.

Code:
        <control type="list" id="3291" description="RecentMoviesDummy">
            <onfocus>Control.SetFocus(3000,0)</onfocus>
            <visible allowhiddenfocus="true">false</visible>
            <itemlayout></itemlayout>
            <content limit="10" target="video">special://skin/extras/playlists/RecentlyWatchedMovies.xsp</content>
        </control>

~Raze
Reply

Logout Mark Read Team Forum Stats Members Help
DBID from another container0