On Fri, Jan 11, 2002 at 11:28:53AM -0500, Neil Gunton wrote: > Jochen Topf wrote: > > I am trying to put a breadcrumbs navigation line on an Embperl web site. > > Something like this: 'Home / Publications / Papers / UNIX', with a link > > behind every word but the last one, which describes the current page. > > > > The idea was to have a Perl function in every page which returns the short > > title for this page. Everything else should work automatically. Finding > > the list of parents should work like this: > > > > /pub/papers/unix.html -> parent is /pub/papers/index.html > > /pub/papers/index.html -> parent is /pub/index.html > > /pub/index.html -> parent is /index.html > > > > i.e. if the filename is index.html look for index.html in the parent directory, > > if it is not, look for index.html in the current directory. > > Here's a function which I did for my site, which does pretty much what > you're talking about:
Thanks for the help, but this is only part of what I need. I don't want to print the "real" URL, but a "translated" short version, like for /pub/papers/index.html I would print Home / Publication / Papers and this can be different for different languages. And the mapping from 'pub' to 'Publication' should be in the /pub/index.html file, so it is easy to keep up to date. Jochen -- Jochen Topf [EMAIL PROTECTED] http://www.remote.org/jochen/ +49-721-388298 --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
