Re: [NTG-context] XML xmldoif struggle!

2019-05-03 Thread Geert Verhaag
Hi Aditya, The ConTeXt team did a great job in writing the manual xml-mkiv.pdf, but I think it is not meant for a beginner. Its contents is rather overwhelming when trying it for the first time. For me, I don't use luatex a lot, so that adds to the difficulty of trying it out. Regards,

Re: [NTG-context] XML xmldoif struggle!

2019-05-02 Thread Aditya Mahajan
On Thu, 2 May 2019, Geert Verhaag wrote: Yes, I got it working! It is somewhat tricky. Trying to understanding the concepts behind all this isn't easy for me, but I'm bashing on. I also find understanding XML processing rules to be complicated. I simply convert the XML to a lua table, and

Re: [NTG-context] XML xmldoif struggle!

2019-05-02 Thread Geert Verhaag
Hi Pablo, Yes, I got it working! It is somewhat tricky. Trying to understanding the concepts behind all this isn't easy for me, but I'm bashing on. Thanks! Regards, Gerard On 02-05-19 14:47, Pablo Rodriguez wrote: On 5/1/19 9:28 PM, Geert Verhaag wrote: Hoi Pablo, Thanks for your

Re: [NTG-context] XML xmldoif struggle!

2019-05-02 Thread Pablo Rodriguez
On 5/1/19 9:28 PM, Geert Verhaag wrote: > Hoi Pablo, > > Thanks for your prompt reply! > > The output Euro set! is printed always, it doesn't matter whether I put > EURO or DOLLAR first?! Hi Geert, my fault, the conditional should read: \xmldoif{#1}{currency[position()==1 and

Re: [NTG-context] XML xmldoif struggle!

2019-05-01 Thread Geert Verhaag
Hoi Pablo, Thanks for your prompt reply! The output Euro set! is printed always, it doesn't matter whether I put EURO or DOLLAR first?! Also I can't find any clue on the suggested page 49 of xml-mkiv.pdf manual, sorry! By the way, in my document it still doesn't seem to work! I'm afraid

Re: [NTG-context] XML xmldoif struggle!

2019-05-01 Thread Pablo Rodriguez
On 4/30/19 9:58 PM, Geert Verhaag wrote: > [...] > \startxmlsetups xml:invoice:invoice >   \xmlfirst{#1}{currency} \par >   \xmldoif{\xmlfirst{#1}{currency}}{contains(text(),'EURO')} { > Euro set! \par >   } > [...] > But the xmldoif command doesn't cause the Euro set be printed?! > >

[NTG-context] XML xmldoif struggle!

2019-04-30 Thread Geert Verhaag
Hi, I've the following XML tag in my XML file:   EURO . with invoice being the root tag! Now I have a setup defined as below (only part!): \startxmlsetups xml:invoice:invoice   \xmlfirst{#1}{currency} \par   \xmldoif{\xmlfirst{#1}{currency}}{contains(text(),'EURO')} { Euro set!