[ Index ]

PHP Cross Reference of DokuWiki

title

Body

[close]

/inc/ -> fulltext.php (summary)

DokuWiki fulltextsearch functions using the index

Author: Andreas Gohr
License: GPL 2 (http://www.gnu.org/licenses/gpl.html)
File Size: 445 lines (13 kb)
Included or required: 9 times
Referenced: 0 times
Includes or requires: 2 files
 inc/indexer.php
 inc/parserutils.php

Defines 10 functions

  ft_pageSearch()
  _ft_pageSearch()
  ft_backlinks()
  ft_mediause()
  ft_pageLookup()
  _ft_pageLookup()
  ft_pagesorter()
  ft_snippet()
  ft_resultCombine()
  ft_queryParser()

Functions
Functions that are not part of a class:

ft_pageSearch($query,&$highlight)   X-Ref
The fulltext search

Returns a list of matching documents for the given query

refactored into ft_pageSearch(), _ft_pageSearch() and trigger_event()


_ft_pageSearch(&$data)   X-Ref
No description

ft_backlinks($id)   X-Ref
Returns the backlinks for a given page

Does a quick lookup with the fulltext index, then
evaluates the instructions of the found pages

ft_mediause($id,$max)   X-Ref
Returns the pages that use a given media file

Does a quick lookup with the fulltext index, then
evaluates the instructions of the found pages

Aborts after $max found results

ft_pageLookup($id,$pageonly=true)   X-Ref
Quicksearch for pagenames

By default it only matches the pagename and ignores the
namespace. This can be changed with the second parameter

refactored into ft_pageLookup(), _ft_pageLookup() and trigger_event()

author: Andreas Gohr <andi@splitbrain.org>

_ft_pageLookup(&$data)   X-Ref
No description

ft_pagesorter($a, $b)   X-Ref
Sort pages based on their namespace level first, then on their string
values. This makes higher hierarchy pages rank higher than lower hierarchy
pages.


ft_snippet($id,$highlight)   X-Ref
Creates a snippet extract

author: Andreas Gohr <andi@splitbrain.org>

ft_resultCombine($args)   X-Ref
Combine found documents and sum up their scores

This function is used to combine searched words with a logical
AND. Only documents available in all arrays are returned.

based upon PEAR's PHP_Compat function for array_intersect_key()

param: array $args An array of page arrays

ft_queryParser($query)   X-Ref
Builds an array of search words from a query




Generated: Tue Dec 2 01:30:01 2008 Cross-referenced by PHPXref 0.7