Example #1
0
 private function getPageLabel(&$pageRecord, $type)
 {
     if ($type == Action::TYPE_PAGE_TITLE) {
         $label = $pageRecord['name'];
         if (empty($label)) {
             $label = ArchivingHelper::getUnknownActionName(Action::TYPE_PAGE_TITLE);
         }
         return $label;
     }
     if ($type == Action::TYPE_OUTLINK || $type == Action::TYPE_DOWNLOAD) {
         return PageUrl::reconstructNormalizedUrl($pageRecord['name'], $pageRecord['url_prefix']);
     }
     return $pageRecord['name'];
 }