Personal Video Database
English => Development => Scripts and Templates => Topic started by: Zacca on October 01, 2009, 12:55:43 pm
-
First of all excuse my English but I'm Italian. I speak e little bit of english but i hope google translator do the miracle :D
Very very very thanks to those who wrote PVD. You are my hero ;D
This is my script for all those interested:
XBMC
%OPTIONS%
replace="&<->&"
replace="<<-><"
replace="><->>"
filter="XML Files|*.nfo"
encoding="UTF8"
imagenameformat="%t%.tbn"
imagepath="\"%OPTIONS%
%HEAD%<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>%HEAD%
<movie>
<title>{%value=title}</title>
<originaltitle>{%value=origtitle}</originaltitle>
<rating>{%value=imdbrating}</rating>
<year>{%value=year}</year>
<plot>{%value=description}</plot>
<tagline>{%value=tagline}</tagline>
<runtime>{%value=length} minuti</runtime>
<mpaa>{%value=mpaa}</mpaa>
<playcount>{%value=count}</playcount>
<genre>{%value=genre}</genre>
<director>{%value=directors}</director>
<studio>{%value=studio}</studio>
<votes>{%value=Voti IMDB custom="true"}</votes>
<top250>{%value=Top 250 IMDB custom="true"}</top250>
<id>{%value=IMDB ID custom="true"}</id>
<poster>{%value=poster}</poster>
{%value=actors template="actors.tpl" maxvalues="10" params="full"}
</movie>
actors.tpl
%HEAD%%HEAD% <actor>
<name>{%param=name}</name>
<role>{%param=role}</role>
</actor>%FOOT%%FOOT%
My questions are:
Is there any way to export the ID of IMDB and the link of photo of the actors ???
Thanks again for everything ;D
-
Hi Zacca,
<id>{%value=url}</id> <==== This is the url in PVD. Needs some work to limit it to only imdb No.
This will insert all URL's (including IMDB) that are in PVD.
i used
%OPTIONS%
replace="http://www.imdb.com/title/<->"
%OPTIONS%
to limit it to just the IMDB No - strips out url part.
These might help too
http://www.videodb.info/forum_en/index.php?topic=1496.0
http://www.videodb.info/forum_en/index.php?topic=1461.msg6329#msg6329
-
Thanks a lot to you Zacca for posting this!
However could you help me understand what to do with the "actors.tpl" part of your script please? Do I need to add it to the previous script or are these two separate scripts that need to be run one after the other?
Thx again.
-
hi deazo,
in main body of export script have:
{%value=actors template="actors.tpl" maxvalues="3" params="full"}
this calls the file "actors.tpl" - maxvalues limits the no of returns. in this case the first 3 actors details. params="full". passes all information about actors (i think)
in actors.tpl file i have
%HEAD%<actor>%HEAD%
<name>{%param=name}</name>
<role>{%param=role}</role>
%FOOT%</actor>%FOOT%
this returns the actor name and the role they played in the film.
-
Great that makes sense, thank you for the clarification!
-
Tnx CAD for the replay of deazo :)
and tnx for my replay ;)
My problem is that i have 3 url... FILMUP for the italian description + Allmovie for the rate and IMDB for the rest
What can i do to delete the first 2 ???
Have u find some solutions to add the thumb on the actors ?? without the name of the image I can't do anything :(
-
hi zacca,
the only way i have found is to limit the output to 1.
imdb has to be first in the list - (you may be able to order this but i haven't tested)
create a file called urls.tpl and have this in it.
{%value}
in xbmc main.ptm file have:
<id>{%value=url template="urls.ptm" maxvalues="1"}</id>
This will limit the no of urls returned to 1. hopefully imdb will be first and gets returned.
NB: replace="http://www.imdb.com/title/<->" to strip leading info no longer works if you use this.
-
ive had a bit of a play and also remapped some fields to get them closer to what xbmc creates.
also limits urls returned to 1. -> the first one. if you want to change this remove/change max values.
nb. this version relies on path info existing (movies have been imported from HD)
if you want to export to a fixed position change nearfiles to nearfiles="c:/<somepath/%t%.nfo"
ill see if i can figure some way to strip leading part of url from imdb url leaving just the "ttxxxxx" No.
maybe recordtemplate= option will allow to be run from called templates. (seems like %option% will only work in main template)
%option%
replace="http://www.imdb.com/title/<->"
%option%
[attachment deleted by admin]
-
hi zacca,
the only way i have found is to limit the output to 1.
imdb has to be first in the list - (you may be able to order this but i haven't tested)
create a file called urls.tpl and have this in it.
{%value}
in xbmc main.ptm file have:
<id>{%value=url template="urls.ptm" maxvalues="1"}</id>
This will limit the no of urls returned to 1. hopefully imdb will be first and gets returned.
NB: replace="http://www.imdb.com/title/<->" to strip leading info no longer works if you use this.
{%value=url template="urls.ptm" maxvalues="1"} don't work for me. The "URLS" don't have command "template".
anyway i have too many movie to reorder :(
I' ll wait for new version ;D
meantime i work to export the movie flag...when i have time unfortunately ;)
-
my bad.
in main export program line should read:
<id>{%value=url template="urls.tpl" maxvalues="1"}</id>
to link to file urls.tpl which has {%value} in it
-
my bad.
in main export program line should read:
<id>{%value=url template="urls.tpl" maxvalues="1"}</id>
to link to file urls.tpl which has {%value} in it
I saw the error and correct, but not work
I don't know why now it work :)
I v change the batch to scan first imdb and second the other.
I'll test it with some movie and i tell u the result