Re: modifying multiple instances of a topic in the same map?


Radu Coravu
 

Hi Chris,

If you want to have the same topic in multiple places of the DITA Map with slightly different content in each of those places you can use either key scopes or branch filtering:

https://oxygenxmlblog.netlify.com/presentation-reuse/reuse_keyscopes.html

https://oxygenxmlblog.netlify.com/presentation-reuse/reuse_branch.html

For example if you use key scopes inside the topic you can use conkeyref to refer to the paragraph and the conkeyref would be resolved to different paragraphs depending on the context.

Regards,
Radu

Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com

On 2/7/2020 1:51 AM, Chris Papademetrious wrote:
If I reuse the same topic in multiple bookmaps, and those bookmaps have a difference in profiling attributes (let's say, @product), then I can customize the topic for each bookmap:
<topic id="mytopic">
  <title>My Topic</title>
  <body>
    <p product="p1">This is customized for Product P1.</p>
    <p product="p2">This is customized for Product P2.</p>
  </body>
</topic>
But let's say I reuse a topic multiple times in the **same book**:
<bookmap>
  <chapter ...>
    <topicref href="mytopic.dita" keys="my1"/>
  </chapter>
  ...
  <chapter ...>
    <topicref href="mytopic.dita" keys="my2"/>
  </chapter>
</bookmap>
What mechanisms are available to customize each instance of that topic in the same book?
Is there a way to push a profiling attribute *down into* a referenced topic from the map?
 - Chris

Join main@dita-users.groups.io to automatically receive all group messages.