[greenstone-users] hyperlinking multiple subject headings

From Belanger, Arthur
DateFri Dec 3 03:53:29 2010
Subject [greenstone-users] hyperlinking multiple subject headings
In-Reply-To (4CF434EA-7070209-cs-waikato-ac-nz)
The javascript solution is pretty clever. I added it to one of my test collections (ver 2.81) and found a problem. It the metadata element has multiple words, Medical Students, the first search by clicking on the generated link works fine but the next document display contains extra "stuff" in the display of the metadata item,

students&h=ddc&t=0&b=0&k=1>Medical Students

and the link is also messed up,

/gsdl/cgi-bin/library?c=yalebcnt&a=q&q=Medical+%3Cspan

This is because highlighting of search terms is on by default. It appears that even the terms in the cgisafe display of metadata are highlighted. I siolved this problem by adding &hl=0 to the javascript line that generates the link.

Would it possible in the next release to eliminate highlighting from cgisafe metadata display? That wouldn't totally solve this problem but it seems to me that if the purpose of cgisafe is to be able to pass the item to a cgi, then highlighting is neither required nor desirable.

Thanks.

--
Arthur Belanger
Medical Library System Manager
ITS Academic Media & Technology
Yale University
PO Box 208065
New Haven, CT 06520-8065

(203) 785-6928
(203) 785-5636, fax

mailto:Arthur.Belanger@Yale.Edu
http://www.yale.edu/its/about/amt
http://info.med.yale.edu/library


NOTE: Yale ITS will NEVER request passwords or other personal information via email. Messages requesting such information are fraudulent and should be deleted.

________________________________
From: greenstone-users-bounces@list.scms.waikato.ac.nz [mailto:greenstone-users-bounces@list.scms.waikato.ac.nz] On Behalf Of Katherine Don
Sent: Monday, November 29, 2010 6:19 PM
To: John Fitzgibbon
Cc: greenstone-users@list.scms.waikato.ac.nz
Subject: Re: [greenstone-users] hyperlinking multiple subject headings

Hi John

The following wiki page might be useful for you
http://wiki.greenstone.org/wiki/index.php/Customizing_collections#How_can_I_hyperlink_individual_metadata_elements.3F

Alternatively, if there will not be too many subjects for each item, you can do something like the following:

{If}{[sibling(1):dc.Subject],<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-help-Arthur+R%2e+Belanger--00-0-1-00-0--4----0-0-11-10-0utfZz-8-00&a=q&h=xx&q=[sibling(1):dc.Subject]">search on [sibling(1):dc.Subject]</a>}

where xx is the 2 letter code for the subjects index.
You can copy the line multiple times, using [sibling(2):dc.Subject] the second time and so on.

See also http://wiki.greenstone.org/wiki/index.php/How_to_format_the_output of your_collection

Regards,
Katherine

John Fitzgibbon wrote:
Hi,

I have a collection of photographs. Each photograph has a number of subject headings which I have listed using Dublin Core. Usually, the 'Subject and Keywords' element is repeated. I am trying to display the list of subject headings near the photograph and make each subject heading a hyperlink to the results page of a subject search for that subject.

I have tried this but it is not linking to the right page and it is linking to all subjects combined rather than each subject individually.


Subject headings: [link][highlight][sibling(All', '):dc.Subject][/highlight][/link]

When I look at any given results page for a subject search I can see that its url ends with '&q=' followed by each word in the subject heading seperated by a '+' sign. How do I use this to build my link? How do I make each subject heading a link?

Any help would be much appreciated.

Regards
John


John Fitzgibbon

w: www.galwaylibrary.ie<http://www.galwaylibrary.ie>

e: info@galwaylibrary.ie<mailto:info@galwaylibrary.ie>

p: 00 353 91 562471

f: 00 353 91 565039

________________________________

This e-mail message has been scanned for content and cleared by MailMarshal Hosted at Galway County Council
T□ an teachtaireacht r□omhphoist seo scan□ilte d'□bhar agus glanta ag MailMarshal at□ □st□lta i gComhairle Chontae na Gaillimhe.

Correspondance is welcome in Irish or in English.

T□ m□le f□ilte roimh chomhfhreagras i nGaeilge n□ i mB□arla.

T□ eolas at□ pr□obh□ideach agus r□nda sa r□omhphost seo agus aon iat□n a ghabhann leis agus is leis an duine/na daoine sin amh□in a bhfuil siad seolta chucu a bhaineann siad. Mura seola□ th□, n□l t□ □daraithe an r□omhphost n□ aon iat□n a ghabhann leis a l□amh, a ch□ip□il n□ a □s□id. M□ t□ an r□omhphost seo faighte agat tr□ dhearmad, cuir an seolt□ir ar an eolas thr□ aischur r□omhphoist agus scrios ansin □ le do thoil.

This e-mail and any attachment contains information which is private and confidential and is intended for the addressee only. If you are not an addressee, you are not authorised to read, copy or use the e-mail or any attachment. If you have received this e-mail in error, please notify the sender by return e-mail and then destroy it.

If you need this email in an alternative format please contact the sender

M□ t□ an r□omhphost seo ag teast□il uait i bhform□id eile d□an teagmh□il leis an duine a sheol chugat □

________________________________


________________________________


_______________________________________________

greenstone-users mailing list

greenstone-users@list.scms.waikato.ac.nz<mailto:greenstone-users@list.scms.waikato.ac.nz>

https://list.scms.waikato.ac.nz/mailman/listinfo/greenstone-users


-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://list.scms.waikato.ac.nz/mailman/private/greenstone-users/attachments/20101202/ef2150d0/attachment-0001.html