Insert an author name in a DITA topic

Post here questions and problems related to editing and publishing DITA content.
gchale3rd
Posts: 21
Joined: Wed Jan 04, 2017 3:48 pm

Insert an author name in a DITA topic

Post 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
Radu
Posts: 9057
Joined: Fri Jul 09, 2004 5:18 pm

Re: Insert an author name in a DITA topic

Post 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
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
gchale3rd
Posts: 21
Joined: Wed Jan 04, 2017 3:48 pm

Re: Insert an author name in a DITA topic

Post 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.
sorin_carbunaru
Posts: 402
Joined: Mon May 09, 2016 9:37 am

Re: Insert an author name in a DITA topic

Post 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
gchale3rd
Posts: 21
Joined: Wed Jan 04, 2017 3:48 pm

Re: Insert an author name in a DITA topic

Post by gchale3rd »

Thanks for updating me about the new variable.
Post Reply