${xpath_eval()} not working in action xml file

Having trouble deploying Oxygen XML Web Author? Got a bug to report? Post it all here.
Johann
Posts: 198
Joined: Wed Jun 17, 2015 12:46 pm

${xpath_eval()} not working in action xml file

Post by Johann »

Hello,

I tried to use the variable ${xpath_eval()} directly in an action xml file in Author Web 25.0.0.0 but it seems that it does not work.

This is an example:

Code: Select all

<a:operation id="InsertFragmentOperation">
			<a:xpathCondition>descendant::gcompanionref</a:xpathCondition>
			<a:arguments>
				<a:argument name="fragment"><imagemap name="imagemap">${xpath_eval(ancestor-or-self::sheet/@id)} TEST</imagemap></a:argument>
                <a:argument name="insertLocation">descendant::gcompanionref</a:argument>
                <a:argument name="insertPosition">After</a:argument>
			</a:arguments>
		</a:operation>
The fragment is well inserted but without the expected id in the content.

Instead, I created a custom operation to handle this.

Regards,

Johann
Bogdan Dumitru
Site Admin
Posts: 142
Joined: Tue Mar 20, 2018 5:28 pm

Re: ${xpath_eval()} not working in action xml file

Post by Bogdan Dumitru »

Hello Johann,

We managed to reproduce the problem, thank you for reporting it.

As a temporary workaround, you can define a custom AuthorOperation [0] [1] that does what you want.

[0] https://www.oxygenxml.com/InstData/Edit ... ation.html
[1] https://www.oxygenxml.com/doc/versions/ ... zb_vsy_dlb
Bogdan Dumitru
http://www.oxygenxml.com
Post Reply