Re: [Xsltforms-support] Possible context()/name() issue
Brought to you by:
alain-couthures
From: <fr...@fl...> - 2013-05-08 07:48:55
|
Hi Alain, Thanks for the clarification, and the solution! Fred Citeren Alain Couthures <ala...@ag...>: > Hi Fred, > >> I hit a possible issue with the combination of the context() and >> name() function. >> >> If however I replace line 67 with >> <xforms:setvalue ref="instance('fruitInstance')/bad-fruit" >> value="context()/name()" /> >> I expect to see 'fruit' when I click 'apple', but XSLTForms returns a >> warning, and the return string is empty. > Because XSLTForms implements an XPath 1.0 engine, functions cannot > be used within a path. >> >> The same problem occurs with local-name(). > For both XPath 1.0 and XPath 2.0, name() and local-name() are > functions which can have a node as parameter: "name(context())" and > "local-name(context())" work as expected. > > Thank you for your feedbacks! > > -Alain > |