View Single Post
Old 10-22-2011, 01:03 PM   #3
uli
Zealot
uli can program the VCR without an owner's manual.uli can program the VCR without an owner's manual.uli can program the VCR without an owner's manual.uli can program the VCR without an owner's manual.uli can program the VCR without an owner's manual.uli can program the VCR without an owner's manual.uli can program the VCR without an owner's manual.uli can program the VCR without an owner's manual.uli can program the VCR without an owner's manual.uli can program the VCR without an owner's manual.uli can program the VCR without an owner's manual.
 
Posts: 110
Karma: 194274
Join Date: Jun 2011
Location: Montreal
Device: Kobo, Calibre
Thanks, works perfectly! Now those extra long Star Wars series are readable!

Here is the final code.

Shows series as initials for Star Wars and Star Trek
Shows full series name for everything else.
ex: 'Star Wars: The New Jedi Order...' = SWTNJO - 11 - Rebel Dream
ex: Culture - 01 - Consider Phlebas

Code:
program: contains(field('series'), 'Star Wars|Star Trek', template('{series:re(([^\s])[^\s]+(\s|$),\1)}{series_index:0>2s| - | - }{title}'), template('{series}{series_index:0>2s| - | - }{title}'))
uli is offline   Reply With Quote