RE: [greenstone-users] Passing search terms to PDF files

From Ben Mottram
DateWed, 15 Nov 2006 08:44:53 -0000
Subject RE: [greenstone-users] Passing search terms to PDF files
Hi Arthur,

Thank you so much for that, it works a treat......

It was the one thing that was stopping someone here using GS over a
rather bizarre Excel spreadsheet.....

Now I can go back to getting the layout right.

Thanks again.

Ben Mottram
-----Original Message-----
From: Arthur R. Belanger [mailto:arthur.belanger@yale.edu]
Sent: 14 November 2006 20:48
To: Ben Mottram
Cc: greenstone-users@list.scms.waikato.ac.nz
Subject: Re: [greenstone-users] Passing search terms to PDF files

Hi Ben.

I've been wanting to do this for some time now only I didn't know that
one could pass parameters to the Acrobat Reader. Now that I know this,
I've been playing around with my SearchVList format statement to see if
I can do this. The search term is kept in the macro _cgiargq_

Here is what I found:

If you the -keep_original_filename option on the PDFPlug line in the
collect.cfg file, the following works when added to the SearchVList
format statement:

<a
href=\\"_httpcollection_/index/assoc/[archivedir]/[Source]#search=&quot;
_cgiargq_&quot;\">
Search PDF</a>

If you do not use the option, the file is renamed doc.pdf so the
following works:

<a
href=\\"_httpcollection_/index/assoc/[archivedir]/doc.pdf#search=&quot;_
cgiargq_&quot;\">
Search PDF</a></td>

These 2 sets of html will add a link to the search results list called
"Search PDF".

You can use the <a href=...&quot;\"> to replace the [ex.srclink] and
then the pdf icon will open the file with the search parameters.

I hope this works for you.

Ben Mottram wrote:
> Hi,
>
> I am building a collection of PDF files in GS2.71 and would like to
> open documents from the search results with extra information included

> within the URL....
>
> In this collection the HTML versions of the PDF files are not
> available to end users.
>
> Currently the format specifies
> "[ex.srclink]{Or}{[ex.thumbicon],[ex.srcicon]}[ex./srclink]" - This is

> substituted at runtime for <a href=<link to pdf file>[Whichever
> Icon]</a> by the greenstone system
>
> However, Adobe allows passing of parameters to the PDF file,
> specifically for opening the PDF internal search engine.... <a
> href=<path to pdf file>#search?"search terms">
>
> Ideally I would like to put the search terms, used to retrieve the
> results from the GS search form, into the [ex.srclink]substitution....
> It seems such a simple idea, yet I suspect it will be difficult or
> impossible, at least in GS2.71.
>
> Regards
>
> Ben Mottram
> Switchboard :- 01305 831400
> ----------------------------------------------------------
> Confidentiality Notice and Disclaimer:
>
> The contents of this e-mail and any attachments are intended only for
> the use of the e-mail addressee(s) shown.
> If you are not that person, or one of those persons, you are not
> allowed to take any action based upon it or to copy it, forward,
> distribute or disclose the contents of it and you should, please,
delete it from your system.
>
> BMT Defence Services Limited does not accept liability for any errors
> or omissions in the context of this e-mail or its attachments which
> arise as a result of Internet transmission, nor does BMT Defence
> Services Limited accept liability for statements which are those of
> the author and not clearly made on behalf BMT Defence Services
Limited.
>
> ----------------------------------------------------
> BMT Defence Services Limited
> Wessex House
> Surrey Close
> Weymouth
> Dorset
> DT4 9GD
>
> Registered in England No. 2326885
>
> Registered Office: Orlando House, 1 Waldegrave Road, Teddington,
> Middlesex, England, TW11 8LZ
>
>
> ______________________________________________________________________> __ This e-mail has been scanned for all viruses by Star. The service
> is powered by MessageLabs. For more information on a proactive
> anti-virus service working around the clock, around the globe, visit:
> http://www.star.net.uk
> ______________________________________________________________________> __
>
>
>
> ----------------------------------------------------------------------> --
>
> _______________________________________________
> greenstone-users mailing list
> greenstone-users@list.scms.waikato.ac.nz
> https://list.scms.waikato.ac.nz/mailman/listinfo/greenstone-users

--
Arthur Belanger
Medical Library System Manager
Academic Media & Technology
ITS
Yale University
100 Church Street South, Suite 107
Mailcode 138
New Haven, CT 06519

(203) 785-6928
(203) 737-2859, fax

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


________________________________________________________________________
This e-mail has been scanned for all viruses by Star. The service is
powered by MessageLabs. For more information on a proactive anti-virus
service working around the clock, around the globe, visit:http://www.star.net.uk
________________________________________________________________________

-------------------------------------------------------------------
Passed by SurfControl E-Mail Content Filter
Switchboard :- 01305 831400
----------------------------------------------------------
Confidentiality Notice and Disclaimer:

The contents of this e-mail and any attachments are intended only
for the use of the e-mail addressee(s) shown.
If you are not that person, or one of those persons, you are not allowed to
take any action based upon it or to copy it, forward, distribute or disclose
the contents of it and you should, please, delete it from your system.

BMT Defence Services Limited does not accept liability for any errors or
omissions in the context of this e-mail or its attachments which arise as a
result of Internet transmission, nor does BMT Defence Services Limited accept
liability for statements which are those of the author and not clearly made
on behalf BMT Defence Services Limited.

----------------------------------------------------
BMT Defence Services Limited
Wessex House
Surrey Close
Weymouth
Dorset
DT4 9GD

Registered in England No. 2326885

Registered Office: Orlando House, 1 Waldegrave Road, Teddington,
Middlesex, England, TW11 8LZ


________________________________________________________________________
This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________