You ask:
This works all fine but I would like to be able to click onto the URL and be led to the place in the internet. How can this be done?
It looks like you have one too many pairs of curly braces encasing the contents of the note
field. Instead of writing
Note = {{\url{http://adsabs.harvard.edu/abs/2010ApJ...720.1691S}}},
you should write
Note = {\url{http://adsabs.harvard.edu/abs/2010ApJ...720.1691S}},
Incidentally, why do you surround the first names and middle initials of the first three authors -- but not the first name of the fourth author -- with round parentheses?
\documentclass{scrartcl}
\usepackage{natbib,url,hyperref}
\hypersetup{colorlinks,allcolors=blue}
\usepackage{filecontents}
\begin{filecontents*}{\jobname.bib}
@Article{Schwamb2010,
Title = {Properties of the Distant Kuiper Belt: Results from the Palomar Distant Solar System Survey},
Author = {(Megan E.) Schwamb and (Michael E.) Brown and (David L.) Rabinowitz and Darin Ragozzine},
Journal = {The Astrophysical Journal},
Year = {2010},
Month = {September},
Note = {\url{http://adsabs.harvard.edu/abs/2010ApJ...720.1691S}},
Number = {2},
Pages = {1691},
Volume = {720},
Doi = {http://dx.doi.org/10.1088/0004-637X/720/2/1691},
Timestamp = {2014.09.21},
Url = {http://m.iopscience.iop.org/0004-637X/720/2/1691/pdf/0004-637X_720_2_1691.pdf}
}
\end{filecontents*}
\begin{document}
\nocite{*}
\bibliographystyle{authordate1}
\bibliography{\jobname}
\end{document}
You also asked:
Furthermore, is it possible to hide the ugly URL behind a clickable hyperref, e.g. the DOI behind the journal abbreviation and the ADS (Astrophysics Data System) behind the paper pages?
This can also be done (though I'm not sure how advisable it is do so...). Just replace the original contents of the journal
and pages
fields with {\href{...}{original content}
. E.g.,
Journal = {\href{http://dx.doi.org/10.1088/0004-637X/720/2/1691}{The Astrophysical Journal}},
and
Pages = {\href{http://adsabs.harvard.edu/abs/2010ApJ...720.1691S}{1691}},
Doing so will generate the following output:
\documentclass{scrartcl}
\usepackage{natbib,url,hyperref}
\hypersetup{colorlinks,allcolors=blue}
\usepackage{filecontents}
\begin{filecontents*}{\jobname.bib}
@Article{Schwamb2010,
Title = {Properties of the Distant Kuiper Belt: Results from the Palomar Distant Solar System Survey},
Author = {Megan E. Schwamb and Michael E. Brown and David L. Rabinowitz and Darin Ragozzine},
Journal = {\href{http://dx.doi.org/10.1088/0004-637X/720/2/1691}{The Astrophysical Journal}},
Year = {2010},
Month = {September},
Number = {2},
Pages = {\href{http://adsabs.harvard.edu/abs/2010ApJ...720.1691S}{1691}},
Volume = {720},
Timestamp = {2014.09.21},
}
\end{filecontents*}
\begin{document}
\nocite{*}
\bibliographystyle{authordate1}
\bibliography{\jobname}
\end{document}
Best Answer
The address with percent encoding is correct for the first argument of
\href
. If\href
is used inside the argument of another command, then the percent%
can be escaped with the backslash\%
to prevent the percent character being interpreted as comment character:Another variation: