TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Possible Duplicate:
Reference plain text

I want to reference an item in a description, without actually displaying the text of the specific item.

I have a description with labeled items

    \item[House\label{bld:house} is a building] \hfill \\
    A house is a building...

And I would want to use something like this

House\ref{bld:house} is something I don't own.

So that the output looks like this

House is something I don't own.

But instead I get this

House is a building is something I don't own.

So it references the whole text within the item. How would I just have a reference with my own individual text, like in HTML (Google)?

And for some reason when I click on the reference it only jumps to the nearest section, but not exactly to the item.

share|improve this question

migrated from stackoverflow.com May 8 '12 at 1:55

This question came from our site for professional and enthusiast programmers.

marked as duplicate by Werner, lockstep, egreg, Stefan Kottwitz May 17 '12 at 10:47

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

I'm not sure if I understand your question correctly, but I think you are using the hyperref package to make hyperlinks in the pdf output? In that case, you can use the \hyperref command to make an HTML-style link to a label. As with HTML you need to specify what text is supposed to be clickable. Does the following code do what you intended? In my pdf viewer, evince, when I click on the word House it correctly jumps to the item in the description list.

    \item[House\label{bld:house} is a building] \hfill \\
    A house is a building...
\hyperref[bld:house]{House} is something I don't own.
share|improve this answer

It "works" for me, in the sense that the output I get is:

House is something I don't own.

Since you didn't have hyperref in your example code, I didn't load it. Perhaps what you have is come conflict with hyperref?

share|improve this answer

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