Graphics, Figures & Tables ⇒ Some combo of href with # in URL, tabularx etc causes errors
-
- Posts: 1
- Joined: Sun Feb 20, 2011 12:06 am
Some combo of href with # in URL, tabularx etc causes errors
A file that is nearly the same as the original file has been uploaded as an attachment called latex-community-question-2-href-error.tex
If you replace the \href{ ... }{ ... } in that file with just zero?, you will have the original file, which has no errors during LaTeX processing, and using dvipdfm produces a nice PDF file, but with no links.
If you keep the file as is, latex gives an error near the } that closes the \colouredbox{grey}{ ... } around the \href.
While experimenting, I have found that if you remove the # from the URL, latex gives no errors, and dvipdfm produces a PDF file with a link, but of course it is not the link I want. But at least it can make some kind of link.
If I remove the \colouredbox{ }, the \tabularx (and the & symbols that were in the \tabularx), the \cmd, and the \frenchspacing from around the \href, latex gives no errors and I can produce a PDF file with the desired link, but then the visual layout is completely changed to something I don't want.
I've tried variations with \protect in a few places near the \href, but without any success.
Does anyone know a way to keep the combination of visual formatting, and URLs with # using hyperref?
Is there another package besides hyperref I should try?
Thanks for any help you can provide.
- Attachments
-
- latex-community-question-2-href-error.tex
- (14.49 KiB) Downloaded 249 times
Learn LaTeX easily with newest books:
The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis
The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more
LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis
-
- Posts: 126
- Joined: Sun Feb 13, 2011 8:36 pm