Enclosed text in reference hyperlinks must not begin with a non-numeric character
This is not the best of solutions, but will at least help to eliminate the problem of multiple adjacent references.master
parent
91c85b1091
commit
8b6e57709d
6
msgfmt
6
msgfmt
|
@ -93,8 +93,10 @@ awk -vid="$id" -vurl_root="$url_root" -vcref_errlog="$cref_errlog" '
|
|||
# reference definitions (footnotes)
|
||||
s#\n\[\([0-9]\+\)\]#</p><p id="ref-\1">&#g;
|
||||
|
||||
# references in text
|
||||
s|\[\([^]]\+\)\]\[\([0-9]\+\)\]|<a href="#ref-\2">\1</a>\[\2\]|g
|
||||
# references in text (note that references that enclose text as a hyperlink
|
||||
# must not start with a number, otherwise they will be considered to be a
|
||||
# reference number)
|
||||
s|\[\([^0-9][^]]\+\)\]\[\([0-9]\+\)\]|<a href="#ref-\2">\1</a>\[\2\]|g
|
||||
s|\[\([0-9]\+\)\]|<sup><a href="#ref-\1">&</a></sup>|g
|
||||
|
||||
# paragraphs
|
||||
|
|
Loading…
Reference in New Issue