Not including DOI if empty?

A place for users to ask each other questions, make suggestions, and discuss Bookends.
Post Reply
FESteward
Posts: 28
Joined: Mon Aug 10, 2020 3:03 pm

Not including DOI if empty?

Post by FESteward »

I'm trying to format my bibliography. I want to include the doi number if it has one. I have watched the video tutorial and read the manual, but I'm still having trouble as it shows up even if the field is empty. My latest attempt is this but it still doesn't work and the text "doi" still shows up. Suggestions?

a (d) “t,” f, v (i), $p. ^pp. $p-. $doi:$ ~u17.~

Also, this is less important, but I'd really like to use single quotations around the title, but when I do that it seems to delete the title entirely and just adds "t" to it. Any ideas for this one?

Thanks,
Hilary
Jon
Site Admin
Posts: 10038
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Not including DOI if empty?

Post by Jon »

I suggest you not use the ~ for forward binding, there are easier (more easily understood) ways to do this:

a (d) “t,” f, v (i), $p. ^pp. $p-.$ doi: $u17.

Note that the spaces before and after "doi" are inside the $ symbols, and so they, and the DOI field, won't be output if there is no DOI.

I'm not sure what you mean by your last comment. You mean

a (d) 't,' f…

doesn't work?

Jon
Sonny Software
FESteward
Posts: 28
Joined: Mon Aug 10, 2020 3:03 pm

Re: Not including DOI if empty?

Post by FESteward »

Thanks so much for your quick response on both questions. The doi fix seems great.

As for the quotation marks, I guess my question is actually because the single quotation marks look a bit odd -- like the first one is backwards. Maybe that's just how they are supposed to look.

Thanks,
Hilary
Attachments
Screen Shot 2022-05-28 at 7.20.14 AM.png
Screen Shot 2022-05-28 at 7.20.14 AM.png (20.02 KiB) Viewed 997 times
Jon
Site Admin
Posts: 10038
Joined: Tue Jul 13, 2004 6:27 pm
Location: Bethesda, MD
Contact:

Re: Not including DOI if empty?

Post by Jon »

I can't reproduce that. Are you sure there is a space between the year's closing parenthesis and the apostrophe? It looks like there is, but I can't be sure. If you can't figure this out, please send the format you are using to support@sonnysoftware.com
Post Reply