From: Thomas Pietrzak Date: Mon, 29 Nov 2021 16:55:51 +0000 (+0100) Subject: isbnsearch hyperrlinks on book titles with isbn entries X-Git-Tag: first-full-draft~84 X-Git-Url: https://git.thomaspietrzak.com/?a=commitdiff_plain;h=4b282238c6aeace1cf7dee0f3cfd7ed05e0dd979;p=hdr.git isbnsearch hyperrlinks on book titles with isbn entries --- diff --git a/plain-withurls.bst b/plain-withurls.bst index f375ab3..74f56d9 100644 --- a/plain-withurls.bst +++ b/plain-withurls.bst @@ -33,6 +33,7 @@ ENTRY year url %% NICOLAS doi %% TOM + isbn %% TOM } {} { label } @@ -561,6 +562,17 @@ FUNCTION {doilink} if$ } +FUNCTION {isbnlink} +{ duplicate$ empty$ +{ pop$ "" } +{ isbn empty$ + { skip$ } + { "\href{https://isbnsearch.org/isbn/" isbn * "}{" * swap$ * "}" * } + if$ +} +if$ +} + FUNCTION {article} { output.bibitem format.authors "author" output.check @@ -628,15 +640,19 @@ FUNCTION {book} if$ new.block - % NICOLAS + % NICOLAS TOM doi empty$ - { url empty$ - { format.btitle } - { "\href{" url * "}{" * format.btitle * "}" * } + { url empty$ + { isbn empty$ + { format.btitle} + { "\href{https://isbnsearch.org/isbn/" isbn * "}{" * format.btitle * "}" * } if$ } - { "\href{http://doi.org/" doi * "}{" * format.btitle * "}" * } + { "\href{" url * "}{" * format.btitle * "}" * } if$ + } + { "\href{http://doi.org/" doi * "}{" * format.btitle * "}" * } + if$ "title" output.check %format.btitle "title" output.check