9 require_once( "QueryPage.php" );
14 class LonelyPagesPage
extends PageQueryPage
{
20 function sortDescending() {
24 function isExpensive() {
29 $dbr =& wfGetDB( DB_SLAVE
);
30 extract( $dbr->tableNames( 'cur', 'links' ) );
32 return "SELECT 'Lonelypages' as type, cur_namespace AS namespace, cur_title AS title, cur_title AS value " .
33 "FROM $cur LEFT JOIN $links ON cur_id=l_to ".
34 "WHERE l_to IS NULL AND cur_namespace=0 AND cur_is_redirect=0";
41 function wfSpecialLonelypages() {
42 list( $limit, $offset ) = wfCheckLimits();
44 $lpp = new LonelyPagesPage();
46 return $lpp->doQuery( $offset, $limit );