Avoid linking URL in Latex
Asked Answered
F

1

6

I'm using hyperref in my latex document. In the references I have an URL, and the hyperref package creates a click able link automatically.

However, I need that that URL is not linked; but the rest of the document internal links should be.

I cannot find a way of just tell latex that avoid that one. For the references, I'm using a bib file.

I already try the \nolinkurl{ulr} macro, but in the final pdf the link is created anyway.

Flouncing answered 9/3, 2011 at 0:59 Comment(0)
O
11

Are you sure that it is a problem with your pdf and not with the pdf viewer?

To test, I created this simple LaTeX document. In the built-in Chrome pdf viewer, all three urls are linked. In Adobe Reader, only the \url{} one is actually linked. Foxit also only creates a link for the explicit \url{} macro.

\documentclass{article}
\usepackage{hyperref}
\begin{document}
This one should link \url{http://www.google.com}

This one should explicitly not link \nolinkurl{http://www.google.com}

This one is absolutely plain text http://www.google.com
\end{document}
Offoffbroadway answered 9/3, 2011 at 2:21 Comment(1)
It didn't occur to me. Thanks. I was using Acrobat Reader, and it link appears linked; but in Chrome is not.Flouncing

© 2022 - 2024 — McMap. All rights reserved.