TeX - LaTeX Asked on December 29, 2020
I want to get online accessed 19-July-2020 before the URL. Currently it’s coming after the URL. The MWE is –
RequirePackage{filecontents}
begin{filecontents}{mybib.bib}
@misc{citekey,
title = {Road accidents in bangladesh - Wikipedia},
note = {Online accessed 19-July-2020},
howpublished =
{retrieved from: url {https://en.wikipedia.org/wiki/Road{_}accidents{_}in{_}bangladesh}}
}
end{filecontents}
documentclass{report}
usepackage{url}
usepackage{cite}
begin{document}
Example citation cite{citekey}
bibliography{mybib}
bibliographystyle{IEEEtran}
end{document}
Is there any way to define the term retrieved from: which I am adding before every url to show it in the reference. I don’t want to write it everytime before every url
in every howpublished
.
Since you're using the IEEEtran
bibliography style, you could make use of the fact that it recognizes a field called url
. A happy side-effect of changing the howpublished
field name to url
(as well as deleting the "retrieved from:" prefix and removing the url{...}
"wrapper") is that the contents of the note
field will no longer be placed last.
documentclass{report}
begin{filecontents}[overwrite]{mybib.bib}
@misc{citekey,
title = {How to add a {URL} to a {LaTeX} bibtex file},
note = {Accessed online 19-July-2020},
url = {https://tex.stackexchange.com/questions/35977/how-to-add-a-url-to-a-latex-bibtex-file}
}
end{filecontents}
usepackage{xurl}
usepackage{cite}
bibliographystyle{IEEEtran}
begin{document}
Example citation cite{citekey}
bibliography{mybib}
end{document}
Answered by Mico on December 29, 2020
Get help from others!
Recent Questions
Recent Answers
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP