Page 1 of 1

Insert an author name in a DITA topic

Posted: Wed Jan 04, 2017 4:11 pm
by gchale3rd
Hello,

I am using the oXygen XML Editor to create DITA topics. I am relatively new to both oXygen and DITA (only a few months of experience at both).

Is there a way to have oXygen automatically insert my name inside of the <author> element in a DITA topic when I create the topic?

The DITA templates I am using all include a <prolog> element that consists of an <author> element. Currently when I create a topic using any of the DITA templates, the <author> element is blank. I have to manually type my name inside of the element.

Thank you.

George Hale

Re: Insert an author name in a DITA topic

Posted: Wed Jan 04, 2017 4:50 pm
by Radu
Hi George,

In Oxygen 19 there will be a new editor variable called ${authorName} which you will be able to use in your new file templates and when a new file will get created from the template, the editor variable will be expanded to the name of the author specified in the Preferences->Editor / Edit Modes / Author / Review page.
Right now as a possible workaround you can use in the new file templates an editor variable called ${system(user.name)} which expands to the user name which you used to log in to your current machine.
You can also define custom editor variables in the Oxygen Preferences->Custom Editor Variables and use them in the new file templates content.
More about editor variables:

https://www.oxygenxml.com/doc/versions/ ... ables.html

Regards,
Radu

Re: Insert an author name in a DITA topic

Posted: Wed Jan 04, 2017 7:22 pm
by gchale3rd
Thank you for the information Radu. I discovered the Editor Variables topic you referenced a few weeks ago. Thanks to what I learned from reading that topic, I'm using the ${uuid} and ${cfn} variables in my templates to automatically populate some data in topics when they are created.

Re: Insert an author name in a DITA topic

Posted: Thu Apr 06, 2017 2:40 pm
by sorin_carbunaru
Hello,

I just wanted to let you know that in the newly released oXygen 19.0 we created the ${author.name} editor variable that expands to the current author set in the Review preferences page.

All the best,
Sorin Carbunaru
oXygen XML

Re: Insert an author name in a DITA topic

Posted: Thu Apr 06, 2017 4:36 pm
by gchale3rd
Thanks for updating me about the new variable.