You are here

Allocate titleoriginal to description via rex?

7 posts / 0 new
Last post
Jagad
Offline
Donator
Joined: 10 years
Last seen: 3 years
Allocate titleoriginal to description via rex?

Hi!
Using se.timefor.tv you get Swedish title and original English title and i like to allocate the original title to the description, but havent found a way yet.
When scrub is done it looks like this:

<title lang="sv">Jims värld</title>

<title lang="xx">According to Jim</title>

 
If using 'mdb-title' I only get the show that previously have been selected during series postprocessing. Many shows without subtitle dont get selected by my choice and how to append these shows original title to the description?
If using 'title' i get the Swedish one.
I was hoping 'titleoriginal' would work, but it aint.  
Can lang attribute be used perhaps? If so how?
 
Regards
Jagad

WGMaker
Offline
WGMaker's picture
WG++ Team memberDonator
Joined: 11 years
Last seen: 17 min
Is the support helpful?
support us

Hi Jagad,

(you have an email)

Unfortunately you cannot differentiate between the two titles using rex (Selection via the lang attribute is not implemented).

The only way I see is that you do this during the front end grab . You have to change the SiteIni for that a little by adding something like:

description.modify {addend| \nOriginal title : 'titleoriginal'}
titleoriginal.modify {clear}

I think in your case all the elements are from the index page, so you need to add the index_ prefix for all the element names.

 

Jan

Jagad
Offline
Donator
Joined: 10 years
Last seen: 3 years

Thanks Jan!
A bit too late. I had to solve it fast due to domestic war reasons, so I did write my own rex postprocessor with XML DOM and Autohotkey doing some merging, some more advanced conditioning when node edtiting, copy and paste element values into other elements, this and that 

smiley

skazi
Offline
Joined: 6 years
Last seen: 6 years

Hi Jan,

Sorry for digging up an old thread but I have exactly the same problem.

Was this feature (selecting title by lang in rex) added by any chance since you wrote the comment above?

Jacek

Jagad
Offline
Donator
Joined: 10 years
Last seen: 3 years

No, it is not added yet! However Blackbear199 speaks about Jan is currently doing a huge REX/MDB update http://webgrabplus.com/content/rex-remove-elements

We dont know when that will be available though. Going the XML DOM way and start learning scripting might be the fastest road for ya.   

skazi
Offline
Joined: 6 years
Last seen: 6 years

Thx for the link.

Regarding XML DOM/scripting, I have quite some experience with these but I wanted to know if it can be done with rex to not reinvent the wheel.

pila
Offline
Joined: 6 years
Last seen: 4 years

I have just tried to move <title lang="xx"> using Rex, but it would appear it will ignore the lang. So, had to solve that using .ini. I had two situations.

1) site which does not use subtitle at all. There I simply converted titleoriginal to the subtitle by replacing:

titleoriginal.scrub ...

into

subtitle.scrub ...

2) site with the "xx" titleoriginal  and functional subtitle I fixed by adding former to the latter, accounting for the possibility of an empty subtitle prior to that, with:

subtitle.modify {addend(not "")|: }
subtitle.modify {addend|'titleoriginal'}
titleoriginal.modify {clear}

At the end Rex moves all items how I want them so the title contains (year) and the original title and the subtitle (should they exist).

 

 

Log in or register to post comments

Brought to you by Jan van Straaten

Program Development - Jan van Straaten ------- Web design - Francis De Paemeleere
Supported by: servercare.nl