Talk:Search
From MediaWiki.org
How to implement the search class - by the wikipedian formerly known as Uncle.bungle
It took me days to piece this together so I'm saving it here for posterity (and since I know I can always check back here :p )
$search = SearchEngine::create(); $search->setLimitOffset(5000,0); /*set max 5000 results starting at result 0 the constructor for SearchEngine will default this to zero so if not set, no results */ $q = $search->replacePrefixes("searchterm"); $matches = $search->searchText($q); while( $result = $matches->next() ) { $t = $result->getTitle(); $link = $t->getFullURL(); echo $link . "\n"; }