I think, one thing easy to remove is the TEXT_OF_FOOTNOTE_HERE and the same for the endnote text place holder and just use the \\1 replace reference, since all of these are clips.
That way if you are marking up existing text it will work easier. I will take a shot at that.
|