Re: [pcgen] HTML export stripping vertical bars when using modified template
- The vertical bar is a pre processor token in PCGen. Therefore, your || is being processed
before the html is written and likely converted to a variable who's name is a null string.
Since that variable is notavailable, nothing is inserted and the || is removed.
it up into two separate if statements.
From: Matt Harris <matt_j_harris@...>
Sent: Sunday, December 11, 2011 8:20 PM
Subject: [pcgen] HTML export stripping vertical bars when using modified template
Not sure which PCGen group this should go to...
I noticed that the csheet_fantasy_laptop.htm sheets weren't taking into
account Acrobatics ranks when Fighting Defensively and Full Defense.
Looking at the output html, I saw that the sheets were essentially for
3.5 (looking at Tumble not acrobatics).
So I added a couple of lines to the resulting himl in what looked to be
the relevant sections:
var acrobaticsRanks = 0;
if ( SkillArr[i].name == "Acrobatics" )
acrobaticsRanks = SkillArr[i].rank;
and modified "else if ( tumbleRanks>= 5)" to "else if (
tumbleRanks>= 5 || acrobaticsRanks>= 3 )"
This worked correctly, so I made a copy of the template and made the
same changes to that.
When I exported my character using my custom template, the html output
was missing the vertical bar characters, i.e.:
"else if ( tumbleRanks>= 5 || acrobaticsRanks>= 3 )" became
"else if ( tumbleRanks>= 5 acrobaticsRanks>= 3 )"
What am I doing incorrectly? Is there an escape character needed for
[Non-text portions of this message have been removed]