On Tue, 12 Feb 2002, Gabriele Bartolini wrote:
> Ciao guys,
> 
>     I am working on a PHP wrapper project for ht://Dig. I read an 
> interesting guide on the contributed work, but I think it is kinda old now, 
> especially by keeping in mind new versions of PHP.

        You might look at the
http://www.htdig.org/files/contrib/wrappers/xmlsearch.tar.gz
        They have used the header/footer/wrapper files to put the search
results into an XML format.

Also the
http://www.htdig.org/files/contrib/wrappers/htsearch-php3.0.1.1.tar.gz
is a start on a PHP page that calls the CGI.

Check out XSLT for use a nice XML parser in PHP.

>     Basically, I would like to create an XML file as output of the htsearch 
> program, then use an XML parser from the PHP script. The PHP opens a pipe 
> to the htsearch program and the XML reads its pointer.

        I'm working on a project to compile htdig with a set of API
functions into 'libhtdig'.
        Part of this will be writing a second very small library
'libhtdigphp' that contains PHP wrappers for libhtdig.

        Ultimately this could be a prefereable approach to forking an
htsearch process and processng the output.  There is a definite 
performance hit for calling a seperate CGI from php vs calling functions
within PHP... context switching, memory paging, & the overhead of parsing
the output etc.

        My ETA on a servicable first version is end of the week.

Thanks

-- 
Neal Richter 
Knowledgebase Developer
RightNow Technologies, Inc.
Customer Service for Every Web Site



_______________________________________________
htdig-dev mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/htdig-dev

Reply via email to