Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I want a hyperlink in a paper that I am writing. I'm using the hyperref package and then \href{<website>}{\nolinkurl{<Thing_with_spaces>}}. How do I go about getting spaces displayed for <Thing_with_spaces>?

\documentclass{article}
\usepackage{hyperref}

\begin{document}

\href{http://tex.stackexchange.com}{\nolinkurl{I Like TEX Stackexchange}}

\end{document}

What will display is ILikeTEXStackexchange with a little blue box around it. I would like spaces to occur between the words.

share|improve this question
    
That works! I wasn't sure why \nolinkurl was included. I am just learning and playing about. Thank you! –  Paul Elfish Jul 25 '13 at 16:18

1 Answer 1

up vote 4 down vote accepted

\nolinkurl is used for displaying a URL, but without activating a link. In this case it's overkill (and it mangles spaces); just use \texttt if you want typewriter type:

\href{http://tex.stackexchange.com}{\texttt{I Like TeX Stackexchange}}
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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