1

This is my first question here, please let me know if I should add more info to the question.

I am preparing a paper using a Springer template svjour3. Due to the peculiarities of the way the references must be shown, after creating the .bib file I am setting directly the result of the .bbl file into the .tex file. So far so good, they are shown correctly.

I am using natbib to show the cites to the references as the year associated with the cited paper / book. And the usual hyperref package.

But I can not get hyperref working properly with any natbib tag (I am using citeyearpar but any other natbib tah makes the same wrong result).

Here is a sample code:

\RequirePackage{fix-cm}
\documentclass[smallextended]{svjour3} 

\usepackage{graphicx}
\usepackage{amsfonts}
\usepackage{mathtools}
\usepackage{url}

\usepackage[round,authoryear]{natbib}
\setcitestyle{round,authoryear}

\usepackage{xxcolor}
\usepackage[colorlinks=true, linkcolor=blue, urlcolor=blue, citecolor = blue]{hyperref}

\setlength{\textwidth}{\dimexpr\pdfpagewidth-2in}
\setlength{\textheight}{\dimexpr\pdfpageheight-2in}

\journalname{ZZZZZ}
%
\begin{document}

\section{Introduction}
\label{intro}

This is a link to example \citeyearpar{example}.


\begin{thebibliography}{22}
\providecommand{\natexlab}[1]{#1}
\providecommand{\url}[1]{\texttt{#1}}
\expandafter\ifx\csname urlstyle\endcsname\relax
  \providecommand{\doi}[1]{doi: #1}\else
  \providecommand{\doi}{doi: \begingroup \urlstyle{rm}\Url}\fi

\bibitem[AF et~al.(2012)AF, AD, and M]{example}
XXX XX, YYYY YY, ZZZZZ Z (2012)
\newblock AIUEO.
\newblock BBBBBB 000(1111):123--345

\end{thebibliography}

\end{document}
% end of file tex

That code produces this result (pdf):

enter image description here

In one hand I can see that natbib has been able to replace the cite with the year of the reference. And in other hand I can see that hyperref has changed the color of the hyperlink to blue, so it has been able to detect that it is indeed a cite. But I cannot click on it, it is not an active hyperlink.

I have been checking other questions regarding hyperref and natbib but I can not find something like this.

What am I doing wrong? I have been hitting my head three days with this. Do I need a kind of "macro" to make natbib and hyperref compatible? Thank you very much.

P.D.1: I am using LEd editor... according to the comments, it might be possible that the problem is the pdf compiler of the editor and not the code itself. Still checking.

0

Thanks for the invaluable feedback. It was the editor! LED is obsolete but MiKTex 2.9 did it perfectly. I will close the question as soon as I can.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.