This project is read-only.

Inserting a line break and a tab character in a reference entry

Jan 20, 2017 at 8:04 PM

In the references section, for each reference, I need the name of the authors to appear alone in the first line. The year of publication should appear in the beginning of the second line followed by a tab character followed by the title and the other fields. Like this:

Haidt, J., S. Koller, and M. Dias
1993    "Affect, culture, and morality, or is it wrong to eat your dog?" Journal of Personality and Social Psychology, 65: 613–628.

I started from ASA style, which resembles what I need in other aspects and tried to change the format contents to insert the line break. The original format for a book looks like this:
   <format>{%Author:2%.}{%Year|"n.d."%{%YearSuffix%}.}{ “%Title%.”}{ &lt;i&gt;%PeriodicalTitle%&lt;/i&gt;,}{ %Month:s%{ %Day%},}{ %Pages:pp. :pp. :%}.{ Retrieved {%MonthAccessed:s% {%DayAccessed%, }}%YearAccessed%}{ (%URL%)}.{ %Comments%.}</format>
I tried insert a \n after the author
    <format>{%Author:2%.\n}{%Year|"n.d."%     .... </format>
but the \n appeared literally in the final document.

I tried an HTML tag <br> and that caused the style to stop working as a whole. I tried an HTML special character but it was ignored. I broke the line manually typing a "return",but that was also useless.

Can I insert a line break just editing the format string or do I need to go deeper in the xslt language?

I also don't know how to insert the tab character. I tried , but got a simple space instead of a tab character.

Thank you for any help,

Jan 22, 2017 at 2:08 PM
I found the answer for the line break. I had to type <br>

For the tab character I tried to use      instead. But that caused the style to disappear from MS Word menu. Still looking for an answer for this.