Quote:
Originally Posted by ownedbycats
Now that it's fixed in source, would changing them back to variables make the template run any more efficiently?
|
Yes, but probably not enough to notice. Turning something into a variable is good from an efficiency standpoint only if the variable is used more than once. In terms of speed improvement: on a reasonable computer, fetching a variable is sub-microsecond. Doing a field reference is probably about 10 times slower, but that isn't really slow in the grand scheme of things.
Quote:
ideally, it'd also check that $#kobobookmark starts with OEBPS/file but I've not quite figured out how to get it working yet.
|
Assuming 'a' is set and that it is not tags-like then something like
Code:
&&
substr(a, 0, 10) == 'OEBPS/file'
should work. You could probably get rid of the test for non-empty.