diff --git a/code/CMSMain.php b/code/CMSMain.php index d1a6e26d..0c557dd6 100755 --- a/code/CMSMain.php +++ b/code/CMSMain.php @@ -36,7 +36,6 @@ class CMSMain extends LeftAndMain implements CurrentPageIdentifier, PermissionPr 'deletefromlive', 'duplicate', 'duplicatewithchildren', - 'getpagecount', 'getversion', 'publishall', 'restore', @@ -1139,36 +1138,6 @@ JS; return $form; } - /** - * Helper function to get page count - */ - function getpagecount() { - ini_set('max_execution_time', 0); - $excludePages = split(" *, *", $_GET['exclude']); - - $pages = DataObject::get("SiteTree", "\"ParentID\" = 0"); - foreach($pages as $page) $pageArr[] = $page; - - while(list($i,$page) = each($pageArr)) { - if(!in_array($page->URLSegment, $excludePages)) { - if($children = $page->AllChildren()) { - foreach($children as $child) $pageArr[] = $child; - } - - - if(!$_GET['onlywithcontent'] || strlen(Convert::xml2raw($page->Content)) > 100) { - echo "
  • " . $page->Breadcrumbs(null, true) . "
  • "; - $count++; - } else { - echo "
  • " . $page->Breadcrumbs(null, true) . " - " . _t('CMSMain.NOCONTENT',"no content") . "
  • "; - } - - } - } - - echo '

    ' . _t('CMSMain.TOTALPAGES',"Total pages: ") . "$count

    "; - } - function publishall() { ini_set("memory_limit", -1); ini_set('max_execution_time', 0);