2004-02-18 02:15:00 +00:00
|
|
|
<?php
|
2004-09-03 20:33:01 +00:00
|
|
|
/**
|
|
|
|
|
* Rebuild search index table from scratch. This takes several
|
|
|
|
|
* hours, depending on the database size and server configuration.
|
|
|
|
|
*
|
|
|
|
|
* @todo document
|
2007-01-20 15:09:52 +00:00
|
|
|
* @addtogroup Maintenance
|
2006-01-07 13:09:30 +00:00
|
|
|
*/
|
2003-05-02 22:55:37 +00:00
|
|
|
|
2004-09-03 20:33:01 +00:00
|
|
|
/** */
|
2004-06-15 15:18:50 +00:00
|
|
|
require_once( "commandLine.inc" );
|
2004-06-26 01:42:16 +00:00
|
|
|
require_once( "rebuildtextindex.inc" );
|
2003-05-02 22:55:37 +00:00
|
|
|
$wgTitle = Title::newFromText( "Rebuild text index script" );
|
|
|
|
|
|
2006-06-27 16:11:47 +00:00
|
|
|
$database = Database::newFromParams( $wgDBserver, $wgDBadminuser, $wgDBadminpassword, $wgDBname );
|
2003-05-02 22:55:37 +00:00
|
|
|
|
2004-06-26 01:42:16 +00:00
|
|
|
dropTextIndex( $database );
|
|
|
|
|
rebuildTextIndex( $database );
|
|
|
|
|
createTextIndex( $database );
|
2003-05-02 22:55:37 +00:00
|
|
|
|
|
|
|
|
print "Done.\n";
|
|
|
|
|
exit();
|
|
|
|
|
|
|
|
|
|
?>
|