Thanks for the advice, I think the .. include:: method will work
adequately for me.

-Christian

On Oct 7, 5:13 am, Georg Brandl <ge...@python.org> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On 10/06/11 22:00, Christian Rohling wrote:
>
> > Hey everyone, I am new to sphinx, and am using it to document a project. I
> > have run into a something that I feel I should be able to do, but cannot
> > find out how. I want to reference a hyperlink section from another file,
> > for example:
>
> > file_a.rst: :ref:`tag_in_file_b`
>
> > file_b.rst: .. tag_in_file_b:http://www.example.com
>
> > I have tried to do this, but so far it doesn't really seem to be working. I
> > can access the hyperlink within the same rst file just fine using something
> > like 'tag_in_file_b'_ ....but not with the :ref: tag. Any input would be
> > greatly appreciated.
>
> This isn't possible, and I would argue that if it worked it would also be
> misleading: :ref: is supposed to make internal references, not external
> hyperlinks.
>
> What you can do is to put your hyperlink references in a common include file,
> and to include that (using ``.. include::``) in all files where you need it
> (if you use it from everywhere, you can also use the rst_epilog config value.)
>
> cheers,
> Georg
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v2.0.18 (GNU/Linux)
>
> iEYEARECAAYFAk6Owp0ACgkQN9GcIYhpnLBzzQCgpbWKR6fJQrXTYxXBqW1ApqfA
> MdIAoKJyWxzKTVEYxn5lArc1khQgo127
> =+xsh
> -----END PGP SIGNATURE-----

-- 
You received this message because you are subscribed to the Google Groups 
"sphinx-dev" group.
To post to this group, send email to sphinx-dev@googlegroups.com.
To unsubscribe from this group, send email to 
sphinx-dev+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/sphinx-dev?hl=en.

Reply via email to