If clause

Having trouble installing Oxygen? Got a bug to report? Post it all here.
MWdal
Posts: 33
Joined: Thu Jun 09, 2022 2:49 pm

If clause

Post by MWdal »

Hello,
I wonder if Oxygen has a function like "if link a does not work, use link b instead"? So if there is a link in a dita file to another dita file, and that link doesn't work (for some reason), can I tell Oxygen to use another link instead?
thanks,
Mikael
Radu
Posts: 9431
Joined: Fri Jul 09, 2004 5:18 pm

Re: If clause

Post by Radu »

Hi Mikael,

To achieve something close to what you want I would probably use links with @keyref for something like this, and this can be done in two ways:

1)

Code: Select all

<xref keyref="targetTopicKeyName"/>
You can choose to define the key so that in one published DITA Map the key resolves to one topic and in another published DITA Map to another.

2)

Code: Select all

<xref keyref="targetTopicKeyName" href="fallbackTopic.dita"/>
If in a certain published DITA Map the key "targetTopicKeyName" is not defined, according to the DITA specification the value of the @href attribute would be used instead.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Post Reply