Greenstone has code for dealing with relative links in source documents,
so I think you can get the effect you're after by tapping into this.
In a simple case, imagine a Greenstone collection with two documents,
doc1.html and doc2.html, each with a relative link to the other, eg:
<a href="doc2.html>Link to doc2.html</a>
When you build this collection, Greenstone will replace the relative
links with calls to the Greenstone "extlink" action:
<a href="/gsdlmod?e=d-00000-00---off-0gsarch--00-0----0-10-0---0---0direct-10---4-----dfr--0-1l--11-en-50---20-about-John+M+Thompson--00-0-21-00-0--4----0-0-11-10-0utfZz-8-00&a=extlink&rl=1&href=http://doc2.html">Link to doc2.html</a>
This means that when you're browsing the built collection and click on
the link, Greenstone will redirect you to the appropriate document.
In your case, you need to extend the option values to have the full
relative paths, since the value must uniquely identify a document:
When your users select one of these options, loading
"/gsdlmod?a=extlink&rl=1&href=[value]" should take you to the correct
Hope this helps,
Daniel Paul O'Donnell wrote:
>I've gone through the archives and documentation, and while I can find
>a number of almost similar examples to this problem, I can't find
>anything that does the crucial thing I need to answer the problem.
>Please excuse me if that's because the answer is so obvious nobody's
>ever asked. I have gone over it with a real expert, though.
>Basically, the issue is that in an HTML document set, I use drop down
>There can be as many as 12 different "views" so a list of links is
>inefficient; it also doesn't get the idea across that all 5 to 12
>documents are actually the same text with different features emphasised.
>Here is the code I use in my HTML:
><form action="" class="changeView">
> <select name="choices" size="1"
> <option value="index.htm">Reading text</option>
> <option selected="selected" value="significant.htm">Significant
> <option value="substantive.htm">Substantive variants</option>
> <option value="orthographic.htm">Orthographic variants</option>
> <option value="analytic.htm">All readings (analytic)</option>
> <option value="parallel.htm">All readings (parallel)</option>
>The trouble in Greenstone is that these URLs on option@value are not
>converted to hash addresses. It appears that what I need to do is write
>the values are correctly converted to Greenstone hashes (if that's the
>right term). There are a fair number of examples of almost identical
>code in the archives, but none that seem to be used for arbitrary
>addresses like this. Any suggestions?