Beispiel #1
0
function html_browse($proj)
{
    if (isset($_GET['b'])) {
        html_blob($proj, $_GET['b']);
    } else {
        if (isset($_GET['t'])) {
            $tree = $_GET['t'];
        } elseif (isset($_GET['tr'])) {
            $tree = $_GET['tr'];
        } else {
            $tree = "HEAD";
        }
        html_tree($proj, $tree);
    }
}
Beispiel #2
0
function html_browse($proj)
{
    $str = '';
    $c = isset($_GET['c']) ? $_GET['c'] : isset($_GET['h']) ? $_GET['h'] : 'HEAD';
    $f = $_GET['f'];
    $str .= '<div class="gitbrowse">';
    $str .= html_pathlinks($proj, $c, $f);
    if (isset($_GET['b'])) {
        $str .= html_blob($proj, $_GET['b'], $f);
    } else {
        $str .= html_tree($proj, $c, $f);
    }
    $str .= '</div>';
    return $str;
}