1

Here is MWE:

\documentclass{scrartcl}
\usepackage[unicode=true,pdfusetitle,
 bookmarks=true,bookmarksnumbered=false,bookmarksopen=false,
 breaklinks=false,pdfborder={0 0 0},pdfborderstyle={},backref=false,colorlinks=true]
 {hyperref}
\hypersetup{
 linkcolor=blue}

\begin{document}

abc
\newpage
$CBC$: \label{cbc}
\newpage
\hyperref[cbc]{$CBC$}

\end{document}

As you can see (if you run it) the \hyperref[cbc]{$CBC$} don't links to the label cbc, instead it links to the top of the page...
Do you know why?

Thank you!

  • 1
    Have you tried with \hypertarget instead \label? – Mensch Apr 7 at 10:05
1

The definition you need to use are

\hypertarget{cbc}{$CBC$}

and

\hyperlink{cbc}{$CBC$}

which means that cbc is the used label and $CBC$ is the displayed text in the document.

So with the complete code

\documentclass{scrartcl}
\usepackage[%
  unicode=true,
  pdfusetitle,
  bookmarks=true,bookmarksnumbered=false,bookmarksopen=false,
  breaklinks=false,pdfborder={0 0 0},pdfborderstyle={},backref=false,colorlinks=true
]{hyperref}
\hypersetup{
 linkcolor=blue}

\begin{document}

abc
\newpage
\hypertarget{cbc}{$CBC$:} % \label{cbc} <===============================
\newpage
Link to cbs working? 

\hyperlink{cbc}{$CBC$} % <==============================================

\end{document}

you get the result:

link

and the target is shown as:

target

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.