${ask} not working properly in Web Author

Hi, I'm creating Author action that should allow user to browse for an image file and then insert appropriate DocBook fragment: <figure xmlns="http://docbook.org/ns/docbook"> <title>${caret}</title> <mediaobject> <imageobject> <imagedata fileref="${ask('Choose image file', relative_url, '')}"/> </imageobject> </mediaobject> </figure> I'm using ro.sync.ecss.extensions.commons.operations.InsertFragmentOperation action for this. This works as expected in desktop Autor. However in Web Author URL chooser appears, I can choose file, filename shows in input box. But when I press OK button to accept chosen filename, input box is cleared and nothing happens. I can close URL chooser only by using Cancel button. Many thanks in advance, Jirka -- ------------------------------------------------------------------ Jirka Kosek e-mail: jirka@kosek.cz http://xmlguru.cz ------------------------------------------------------------------ Professional XML and Web consulting and training services DocBook/DITA customization, custom XSLT/XSL-FO document processing ------------------------------------------------------------------ Bringing you XML Prague conference http://xmlprague.cz ------------------------------------------------------------------

Hi, I managed to reproduce this problem. It is caused by the ${caret} editor variable which is not supported in Web Author. If you remove it, the action will start working. You will not lose any functionality since the caret is automatically placed in the first leaf node. I added an internal issue to fix the handling of the ${caret} editor variable for such cases. Best, Cristian On 10/16/2018 1:58 PM, Jirka Kosek wrote:
Hi,
I'm creating Author action that should allow user to browse for an image file and then insert appropriate DocBook fragment:
<figure xmlns="http://docbook.org/ns/docbook"> <title>${caret}</title> <mediaobject> <imageobject> <imagedata fileref="${ask('Choose image file', relative_url, '')}"/> </imageobject> </mediaobject> </figure>
I'm using ro.sync.ecss.extensions.commons.operations.InsertFragmentOperation action for this.
This works as expected in desktop Autor. However in Web Author URL chooser appears, I can choose file, filename shows in input box. But when I press OK button to accept chosen filename, input box is cleared and nothing happens. I can close URL chooser only by using Cancel button.
Many thanks in advance,
Jirka
_______________________________________________ oXygen-user mailing list oXygen-user@oxygenxml.com https://www.oxygenxml.com/mailman/listinfo/oxygen-user

On 16.10.2018 13:39, Cristi Talau wrote:
I managed to reproduce this problem. It is caused by the ${caret} editor variable which is not supported in Web Author. If you remove it, the action will start working. You will not lose any functionality since the caret is automatically placed in the first leaf node.
Perfect, many thanks. -- ------------------------------------------------------------------ Jirka Kosek e-mail: jirka@kosek.cz http://xmlguru.cz ------------------------------------------------------------------ Professional XML and Web consulting and training services DocBook/DITA customization, custom XSLT/XSL-FO document processing ------------------------------------------------------------------ Bringing you XML Prague conference http://xmlprague.cz ------------------------------------------------------------------

Hello, I am writing to let you know that version 21 of Oxygen XML Web Author is not released and the ${caret} editor variable is now supported. Best, Cristian On 10/16/2018 3:32 PM, Jirka Kosek wrote:
On 16.10.2018 13:39, Cristi Talau wrote:
I managed to reproduce this problem. It is caused by the ${caret} editor variable which is not supported in Web Author. If you remove it, the action will start working. You will not lose any functionality since the caret is automatically placed in the first leaf node. Perfect, many thanks.
participants (2)
-
Cristi Talau
-
Jirka Kosek