View Single Post
Old 08-31-2018, 06:20 PM   #2
Sam Sahara
Connoisseur
Sam Sahara doesn't litterSam Sahara doesn't litterSam Sahara doesn't litter
 
Posts: 79
Karma: 228
Join Date: Aug 2014
Device: lambda k21
Quote:
Originally Posted by Sam Sahara View Post
EDIT ===============================

I've tried putting in a book the following line

Code:
<?bag value="3" content="Ferrara"?>
and trying the following expression to add the word "Ferrara" in the ToC:

Code:
//processing-instruction("bag")[@value="3"]/@content
but I get only
Code:
"calibre, version 3.30.0
ERROR: No items found: No items were found that could be added to the Table of Contents.
Same result with the following expression:
Code:
substring-before(substring-after(//processing-instruction('bag'), 'value="3" content="'), '"')
Sam Sahara is offline   Reply With Quote