예제 #1
0
파일: revision.php 프로젝트: laiello/suitex
         $vars['nextrevurl'] = $revurl . 'rev=' . $nextRev;
         //echo 'NEXT='.$vars['nextrevurl'].'<br/>';
     }
     unset($vars['error']);
     $history = $svnrep->getLog($path, $rev, 1, false, 2, $peg);
 }
 if (isset($history->entries[1])) {
     $prevRev = $history->entries[1]->rev;
     $prevPath = $history->entries[1]->path;
     $vars['prevrev'] = $prevRev;
     $vars['prevrevurl'] = $revurl . 'rev=' . $prevRev;
     //echo 'PREV='.$vars['prevrevurl'].'<br/>';
 }
 // Save the entry from which we pull information for the current revision.
 $logEntry = isset($history->entries[0]) ? $history->entries[0] : null;
 $bugtraq = new Bugtraq($rep, $svnrep, $ppath);
 $vars['action'] = '';
 $vars['rev'] = $rev;
 $vars['peg'] = $peg;
 $vars['path'] = htmlentities($ppath, ENT_QUOTES, 'UTF-8');
 $vars['date'] = $logEntry ? $logEntry->date : '';
 $vars['author'] = $logEntry ? $logEntry->author : '';
 $vars['log'] = $logEntry ? nl2br($bugtraq->replaceIDs(create_anchors(xml_entities($logEntry->msg)))) : '';
 $isDir = @$_REQUEST['isdir'] == 1 || $path == '' || $path == '/';
 $vars['logurl'] = $config->getURL($rep, $path, 'log') . $passRevString . ($isDir ? '&amp;isdir=1' : '');
 $vars['loglink'] = '<a href="' . $vars['logurl'] . '">' . $lang['VIEWLOG'] . '</a>';
 $dirPath = $isDir ? $path : dirname($path) . '/';
 $vars['directoryurl'] = $config->getURL($rep, $dirPath, 'dir') . $passRevString . '#' . anchorForPath($dirPath);
 $vars['directorylink'] = '<a href="' . $vars['directoryurl'] . '">' . $lang['LISTING'] . '</a>';
 if ($path != $dirPath) {
     $vars['filedetailurl'] = $config->getURL($rep, $path, 'file') . $passRevString;
예제 #2
0
파일: log.php 프로젝트: laiello/suitex
     $vars['difflink'] = '<a href="' . $vars['diffurl'] . '">' . $lang['DIFFPREV'] . '</a>';
 }
 if ($rep->isRssEnabled()) {
     $vars['rssurl'] = $config->getURL($rep, $path, 'rss') . $isDirString . ($peg ? 'peg=' . $peg : '');
     $vars['rsslink'] = '<a href="' . $vars['rssurl'] . '">' . $lang['RSSFEED'] . '</a>';
 }
 if ($rev != $youngest) {
     if ($path == '/') {
         $vars['goyoungesturl'] = $config->getURL($rep, '', 'log') . $isDirString;
     } else {
         $vars['goyoungesturl'] = $config->getURL($rep, $path, 'log') . $isDirString . 'peg=' . ($peg ? $peg : $rev);
     }
     $vars['goyoungestlink'] = '<a href="' . $vars['goyoungesturl'] . '">' . $lang['GOYOUNGEST'] . '</a>';
 }
 // We get the bugtraq variable just once based on the HEAD
 $bugtraq = new Bugtraq($rep, $svnrep, $ppath);
 $vars['logsearch_moreresultslink'] = '';
 $vars['pagelinks'] = '';
 $vars['showalllink'] = '';
 $history = $svnrep->getLog($path, $startrev, $endrev, true, $max, $peg);
 if (empty($history)) {
     $vars['warning'] = 'Revision ' . $rev . ' of this resource does not exist.';
 } else {
     // Get the number of separate revisions
     $revisions = count($history->entries);
     if ($all) {
         $firstrevindex = 0;
         $lastrevindex = $revisions - 1;
         $pages = 1;
     } else {
         // Calculate the number of pages