diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2006-10-11 18:12:39 +0000 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2006-10-11 18:12:39 +0000 |
commit | 183851b06bd6c52f3cae5375f433da720d410447 (patch) | |
tree | a477257decbf3360127f6739c2f9d0ec57a03d39 /includes/SpecialLonelypages.php |
MediaWiki 1.7.1 wiederhergestellt
Diffstat (limited to 'includes/SpecialLonelypages.php')
-rw-r--r-- | includes/SpecialLonelypages.php | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/includes/SpecialLonelypages.php b/includes/SpecialLonelypages.php new file mode 100644 index 00000000..326ae54d --- /dev/null +++ b/includes/SpecialLonelypages.php @@ -0,0 +1,58 @@ +<?php +/** + * + * @package MediaWiki + * @subpackage SpecialPage + */ + +/** + * + * @package MediaWiki + * @subpackage SpecialPage + */ +class LonelyPagesPage extends PageQueryPage { + + function getName() { + return "Lonelypages"; + } + + function sortDescending() { + return false; + } + + function isExpensive() { + return true; + } + function isSyndicated() { return false; } + + function getSQL() { + $dbr =& wfGetDB( DB_SLAVE ); + extract( $dbr->tableNames( 'page', 'pagelinks' ) ); + + return + "SELECT 'Lonelypages' AS type, + page_namespace AS namespace, + page_title AS title, + page_title AS value + FROM $page + LEFT JOIN $pagelinks + ON page_namespace=pl_namespace AND page_title=pl_title + WHERE pl_namespace IS NULL + AND page_namespace=".NS_MAIN." + AND page_is_redirect=0"; + + } +} + +/** + * Constructor + */ +function wfSpecialLonelypages() { + list( $limit, $offset ) = wfCheckLimits(); + + $lpp = new LonelyPagesPage(); + + return $lpp->doQuery( $offset, $limit ); +} + +?> |