Add the other existing $skin.css/.js to the message files too to be consistent
[mediawiki.git] / includes / SpecialLonelypages.php
blob5aafac7dd5ed64e789d6ebabf050499a9984b461
1 <?php
2 /**
3 * @file
4 * @ingroup SpecialPage
5 */
7 /**
8 * A special page looking for articles with no article linking to them,
9 * thus being lonely.
10 * @ingroup SpecialPage
12 class LonelyPagesPage extends PageQueryPage {
14 function getName() {
15 return "Lonelypages";
17 function getPageHeader() {
18 return wfMsgExt( 'lonelypagestext', array( 'parse' ) );
21 function sortDescending() {
22 return false;
25 function isExpensive() {
26 return true;
28 function isSyndicated() { return false; }
30 function getSQL() {
31 $dbr = wfGetDB( DB_SLAVE );
32 list( $page, $pagelinks ) = $dbr->tableNamesN( 'page', 'pagelinks' );
34 return
35 "SELECT 'Lonelypages' AS type,
36 page_namespace AS namespace,
37 page_title AS title,
38 page_title AS value
39 FROM $page
40 LEFT JOIN $pagelinks
41 ON page_namespace=pl_namespace AND page_title=pl_title
42 WHERE pl_namespace IS NULL
43 AND page_namespace=".NS_MAIN."
44 AND page_is_redirect=0";
49 /**
50 * Constructor
52 function wfSpecialLonelypages() {
53 list( $limit, $offset ) = wfCheckLimits();
55 $lpp = new LonelyPagesPage();
57 return $lpp->doQuery( $offset, $limit );