Download Firefox: WindowsMac OS X
logo       
Google Custom Search
    AddThis Social Bookmark Button

Re: Standard Library Docs online at ruby-doc.org: msg#00016

Subject: Re: Standard Library Docs online at ruby-doc.org
On Tue, 2003-11-25 at 02:00, jbritt@xxxxxxxxxxxx wrote:
> Simon Kitching wrote:
> > The link would presumably be a relative path, though, rather than
> > "/css/stdlib.css" as shown above...
> 
> I suggested a path relative to the root of the site, rather than 
> relative to the documents themselves, so that if the stdlib docs were 
> moved up or down a directory the path would still work.

But if I download the files to my PC in order to work offline, then
access them via file://.... they will all be broken if they contain
absolute paths in hrefs. When working via a modem, it is *very* common
to download useful docs like this and install them locally; I presume
you have a connection that isn't dialup :-)

I guess there could be *two* versions : one for "online hosting" and a
different version for downloading for offline use, but that seems
additional unnecessary work, unless some automated tool can do the
tweaking.

Or people could be told to use wget, with the option that tweaks
internal URLs in files. Too bad for windows users!

Or people could be told that when they download files, they must run a
webbrowser on their PC and access them via http://localhost rather than
access the files via a file:// url.

I still thing that having one version of the files that works both via a
webbrowser and via file: urls is the easiest. It only takes a little
care to make this work.


> > 
> > 
> >>Sure.  I'll clearly mark the link as "ruby-doc.org" though, so it
> >>doesn't appear weird when people browse it offline.
> 
> If the URL doesn't specify ruby-doc.org then it doesn't really matter.
> A link to ruby-doc.org would be fine, but I'm thinking that others may 
> decide to host the docs as well.

I think the concept of "go to the root of the documentation", and "go to
the real ruby-doc.org" site are different, and should have different
links..

I suggest the first should be implemented as 
<a href="../../index.html">documentation root</a>  [1]
and the latter as
<a href="http://ruby-doc.org";>ruby-doc site</a>

[1] the exact path depends on where the containing file is relative to
the root of the site. Yes, this is sometimes tricky to manage.

> 
> James

I do feel a bit guilty debating this issue when it is Gavin who is
actually doing the work. Sorry, Gavin :-)

Regards,

Simon





<Prev in Thread] Current Thread [Next in Thread>