View Single Post
Old 01-16-2021, 05:08 PM   #1
ownedbycats
Custom User Title
ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.ownedbycats ought to be getting tired of karma fortunes by now.
 
ownedbycats's Avatar
 
Posts: 11,023
Karma: 75555555
Join Date: Oct 2018
Location: Canada
Device: Kobo Libra H2O, formerly Aura HD
Template: Show only first value in a taglike

I have this template in KoboTouchExtended's subtitle field:

Code:
program:
	if field('#serieslike') then
		 template('{#serieslike} #{#serieslike_index:0>2s}')
	else
		if field('#taglike') then
			template('{#taglike} | {#enum}')
		fi
	fi
(For context, #serieslike is for reading lists, #taglike is fanfic category, and #enum is fanfic status.)

This works as expected. However, I noticed books with multiple values in #taglike tend to cause the subtitle length to overflow on my Kobo. So I'd like it to just display the first value. How do I do that?


Last edited by ownedbycats; 01-16-2021 at 05:12 PM.
ownedbycats is offline   Reply With Quote