# How to reference websites using bibliography style ieeetr?

I have in my list.bib file a reference:

@misc{DonoraSmog,
author = {Wikipedia},
title = {1948 Donora Smog},
month = jun,
year = {2009},
url = {http://www.test.org/doe/}
}


But, once compiled, it does not show the website in the pdf. I am using the package {url}.

Also, is there a package that does APA citing ?

(too long for comment)

With the following code, the website is displayed.

\documentclass{IEEEtran}
\usepackage{filecontents}
\begin{filecontents*}{sampbib.bib}
@misc{DonoraSmog,
author = {Wikipedia},
title = {1948 Donora Smog},
month = jun,
year = {2009},
url = {http://www.test.org/doe/}
}
\end{filecontents*}
\usepackage{url}
\bibliographystyle{IEEEtran}
\begin{document}
\nocite{*}
\bibliography{sampbib}
\end{document}


If this code doesn't work for you as such, you may have to provide your code for testing.

• My document class is article, is that a big deal? And I am using an external .bib file. – CivilSigma Sep 25 '15 at 1:57
• @CivilSigma As long as we don't know it, it is ;-). My code above works with article class too. And I am using external bib file too. – user11232 Sep 25 '15 at 1:58
• Oh wow! I just typed \nocite{DonoraSmog} and all my sources displayed their respective urls. LaTeX is even weirder than computer programming! Thank you for your help Mr.Kumar :D – CivilSigma Sep 25 '15 at 2:02
• Any idea how I can center "References" ? – CivilSigma Sep 25 '15 at 2:04
• @CivilSigma Add these lines to your preamble: \usepackage{xpatch} \xpatchcmd{\thebibliography}{\section*{\refname}}{\section*{\hfil\refname}}{}{} – user11232 Sep 25 '15 at 2:09