Koozali.org: home of the SME Server

Obsolete Releases => SME 7.x Contribs => Topic started by: holck on September 19, 2009, 10:57:24 PM

Title: Document search facility?
Post by: holck on September 19, 2009, 10:57:24 PM
I have a number of PDF-documents on my server and wanted my users to be able to search the contents of these documents. So I installed ksearch from http://www.kscripts.com/, and after some adjustments it seems to work fine. So two questions:
Title: Re: Document search facility?
Post by: stephen noble on September 20, 2009, 02:23:54 AM
Thanks, start with a howto
this is easier to refine than a contrib, and makes creating a contrib later easier
Title: Document search facility: How To
Post by: holck on September 30, 2009, 05:23:52 PM
This is my first attempt at a HowTo so please bear with me and help improve it ...

I needed a document search facility for my users, essentially to make them able to search through various notes, memos etc. available on the web server. I found a usable script at www.kscripts.com, and have adjusted it a bit to make it more feasible for the SME-server, so I have produced a new file package you can get here: http://ibsgaardenprivat.dk/ksearch1.5b.tgz (http://ibsgaardenprivat.dk/ksearch1.5b.tgz)

Here is a copy of my new README, part of the file package:


== GENERAL INSTALLATION INSTRUCTIONS: ==

You will need a text editor, and access to your server to edit and run scripts. See faqs.html for details.

The contents of the directory "search" will be copied to a newly created directory on the web server "/opt/ksearch".

Title: Re: Document search facility?
Post by: cactus on September 30, 2009, 05:54:24 PM
Please put your howto in the wiki, in the category howto's the forums as documentation finds a better place there. Thanks in advance.
Title: Re: Document search facility?
Post by: Stefano on September 30, 2009, 06:16:29 PM
I think that editing directly files is not a good idea because:
- each time you upgrade you will loose your wiork
- each time you upgrade maybe the files will be different so editing them will be difficult

my 2c
Title: Re: Document search facility?
Post by: holck on September 30, 2009, 10:49:14 PM
I have tried to add this as a HowTo: http://wiki.contribs.org/Document_search (http://wiki.contribs.org/Document_search)
Title: Re: Document search facility?
Post by: cactus on September 30, 2009, 11:08:42 PM
I have tried to add this as a HowTo: http://wiki.contribs.org/Document_search (http://wiki.contribs.org/Document_search)
Thanks very much, some quick advises as I really need to be doing something else right now:

Use preformatted text (indent with a space) for command instructions as well as the content of files. Please do not use all caps in headers, let the wiki formatting do it's work on the headers, oh and while we are on the topic of headers please do not use second (==) level, but start with third (===).

Traditionally user commands (even the original author's when not immediately relevant to the instructions) are placed on the discussion/talk pages.

Thanks for your work so far.
Title: Re: Document search facility?
Post by: holck on October 01, 2009, 08:52:22 AM
Thanks for the comments and suggestions.

I agree with Stefano that in general it is not a good idea to make your own changes to others' code, for the reasons he mentions, and I will contact ksearch and ask them to include my changes. But there were errors in source code and tar-archive, and some of my changes made the code and instructions more convenient for the SME-server.

I will follow Cactus' recommendations, but can't figure out how to use pre-formatted text in lists, and I don't know what is meant by "user commands"?
Title: Re: Document search facility?
Post by: Stefano on October 01, 2009, 09:00:13 AM
I agree with Stefano that in general it is not a good idea to make your own changes to others' code, for the reasons he mentions, and I will contact ksearch and ask them to include my changes. But there were errors in source code and tar-archive, and some of my changes made the code and instructions more convenient for the SME-server.

I would ask them to set an inclusion file where to store all the variables.. in such way we can easily generate (via a template) it and the integration with SME would be easyer

ciao
Title: Re: Document search facility?
Post by: cactus on October 01, 2009, 11:44:29 AM
I would ask them to set an inclusion file where to store all the variables.. in such way we can easily generate (via a template) it and the integration with SME would be easyer

ciao
I have not taken a look at the installation routines very closely, but if ksearch provides and RPM, we can write a howto how to make a template for them which we can use if someone is ever to create a (integrational) smeserver-ksearch rpm.