Page 1 of 1

Schematron "see" attribute and Ampersand

Posted: Fri Feb 10, 2017 6:21 pm
by grethelgomez
Hello,
I’m new to Schematrons, and in one of the patterns I need to include a URL to a reference material. The URL requires the use of ampersand, as in the following example:

Code: Select all

<pattern id=”myExample” see=”https://www.reference.com?source=something&action=myAction&section=mySection”>


The error message I receive in <oXygen/> XML Developer 18.0 is: The reference to entity "action" must end with the ';' delimiter.

I’ve used several combinations, tried to escape the ampersand (%26, &#38; and &amp;), but I don’t get the result I need: a valid link to the reference when clicking it on the Error Result viewport pane in <oXygen/> XML Editor 18.0.

Suggestions?
Thanks in advance,
Grethel.

Re: Schematron "see" attribute and Ampersand

Posted: Mon Feb 13, 2017 9:59 am
by Radu
Hi Grethel,

The & character is a special XML character used to refer to entities. So it needs to be escaped to "&amp;" like:

Code: Select all

<pattern id=”myExample” see=”https://www.reference.com?source=something&amp;action=myAction&amp;section=mySection”>


After the validation, in the results view there is a special "Info" column with a small book-like icon on which you need to press to go to the @see location.

Regards,
Radu

Re: Schematron "see" attribute and Ampersand

Posted: Tue Feb 14, 2017 6:45 pm
by grethelgomez
Thank you for your reply, Radu.

However, I have tried all of the following combinations without obtaining a valid link to the reference:

Code: Select all

<pattern id=”myExample” see=”https://www.reference.com?source=something&amp;action=myAction&amp;section=mySection”>

Code: Select all

<pattern id=”myExample” see=”https://www.reference.com?source=something#38;action=myAction#38;section=mySection”>

Code: Select all

<pattern id=”myExample” see=”https://www.reference.com?source=something%26action=myAction%26section=mySection”>


The navigator only accepts : https://www.reference.com?source=something&action=myAction&section=mySection

This means I need to to escape the ampersand in a way that when clicking on the book-like icon in the results view, it turns into &.

Do you have other suggestions?

Thanks,

Grethel.

Re: Schematron "see" attribute and Ampersand

Posted: Wed Feb 15, 2017 11:03 am
by Radu
Hi Grethel,

I tested and reproduced the issue on our side.
Using &amp; is the proper way to escape the & in the Schematron but Oxygen should have unescaped the @see attribute value when presenting it as a more details destination on the error.
I added an internal issue for this, we'll try to fix it in Oxygen 19 (April-May this year).

Regards,
Radu

Re: Schematron "see" attribute and Ampersand

Posted: Thu Feb 16, 2017 10:38 pm
by grethelgomez
Hello, Radu.

Thank you very much for your reply.
Looking forward to Oxygen 19,
Grethel.

Re: Schematron "see" attribute and Ampersand

Posted: Fri Feb 17, 2017 9:03 am
by Radu
Hi Grethel,

About every couple of weeks we also release Oxygen 18.1 minor bug fix releases, I managed to schedule the fix for the next Oxygen 18.1 minor bug fix release, so you might have the fix sooner. We'll update this forum thread when the fix is available.

Regards,
Radu

Re: Schematron "see" attribute and Ampersand

Posted: Wed Mar 29, 2017 12:32 pm
by Radu
Hi,

Just to update this thread the latest Oxygen 18.1 builds available on our web site should have a fix for this.

Regards,
Radu

Re: Schematron "see" attribute and Ampersand

Posted: Thu Apr 20, 2017 10:30 pm
by grethelgomez
Hello Radu,

I downloaded Oxygen 18.1 (build 2017020917) and tested, but it is not working for me. The escaped ampersand in the @see attribute doesn't turn to the unescaped ampersand ("&") in the "more details destination" on the error pane.

Is there something else I should do?

Thanks,
Grethel.

Re: Schematron "see" attribute and Ampersand

Posted: Fri Apr 21, 2017 12:15 pm
by Radu
Hi Grethel,

Sorry, my mistake. The problem is fixed in Oxygen 19.0.
We had plans to fix it for Oxygen 18.1, we fixed in our internal branch but as we did not create new Oxygen 18.1 kits containing the fix, the fix is not contained in the Oxygen 18.1 kits we have on our web site.

Regards,
Radu

Re: Schematron "see" attribute and Ampersand

Posted: Fri Apr 21, 2017 3:44 pm
by grethelgomez
Hi Radu,

It's too bad. I will have to wait until I can have 19. Looking forward to it!

Thanks and have a nice day,
Grethel.