Beispiel #1
0
include "../../php/site.php";
include "../../php/forum.php";
include "../../php/twitter.php";
include "../../php/db.php";
include "../../php/irc.php";
include "../../php/bugzilla.php";
$RowsToShow = 20;
$t = new Twitter();
$f = new Forum();
$irc = new IRC();
$bugzilla = new Bugzilla();
$twitterSearchItems = $t->render_search_mobile("browserplus", $RowsToShow);
$twitterUserItems = $t->render_user_mobile("browserplus", $RowsToShow);
$max = $irc->get_max_id();
$results = $irc->get_rows($max, $RowsToShow);
$ircItems = $irc->render_mobile($results, $max);
$issueItems = $bugzilla->render_mobile($RowsToShow);
$forumItems = $f->render_mobile($RowsToShow);
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
         "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
  <title>BrowserPlus</title>
  <meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;"/>
  <link rel="apple-touch-icon" href="/m/dashboard-icon.png" />
  <style type="text/css" media="screen">@import "/iui/dashboardx.css";</style><!-- http://www.phpied.com/cssmin-js/ -->
  <script type="application/x-javascript" src="/iui/iuix.js"></script>
  <style type="text/css" media="screen">
  .items li {font-size:100%;font-weight:normal;}
Beispiel #2
0
    $xml = simplexml_load_string($atom);
    $s = "<ul>";
    foreach ($xml->entry as $item) {
        if ($max-- == 0) {
            break;
        }
        $link = (string) $item->link['href'];
        $title = (string) $item->title;
        $s .= "<li><a href=\"{$link}\">{$title}</a></li>";
    }
    $s .= "</ul>";
    return render_widget("blog", "BrowserPlus: <a href=\"/blog/\">Blog</a>", $s);
}
// IRC Transcript
$irc = new IRC();
$results = $irc->get_rows($irc->get_max_id(), $tableRowsToShow);
$ircnav = l("#browserplus", "/discuss/");
$irctable = render_table($results, "stamp", "who", "utterance", array("show_long_dates" => true, "top_nav" => "<strong>IRC: {$ircnav}</strong>"));
//$ircwidgets = $irc->render_widget("day") . $irc->render_widget("week") . $irc->render_widget("month");
$ircwidgets = $irc->render_widget("week");
// GIT Projects
$git = new GIT();
$results = $git->get_rows($tableRowsToShow);
$gitnav = "<strong>GitHub: <a href=\"http://www.github.com/browserplus/\">BrowserPlus</a></strong>";
$gittable = render_table($results, "tcommit", "project", "msg", array("show_long_dates" => true, "top_nav" => $gitnav, "url_key" => "url", "url_pat" => "%s"));
$gitwidgets = $git->render_project_widget();
// bugzilla issues
$bugzilla = new Bugzilla();
$issuewidget = $bugzilla->render_widget($listItemsToShow);
// Links Widget
$linkswidget = get_links_widget();
Beispiel #3
0
    $rcount = count($results);
    if ($rcount == 0) {
        $blurb = "No IRC results match that query.";
    } else {
        $blurb = "Results that match '" . h($_GET['search']) . "':";
    }
    $rcount = count($results);
    $nav = l("Current", "/discuss/");
} else {
    if (isset($_GET['id'])) {
        $id = (int) $_GET['id'];
        $id = $max_id - $id < 0 ? $max_id : $id;
    } else {
        $id = $max_id;
    }
    $results = $irc->get_rows($id, IRC_MAX_ROWS);
    $rcount = count($results);
    if ($rcount > 0) {
        $first_id = $results[0]["id"];
        $last_id = $results[count($results) - 1]["id"];
        $next_id = $last_id + IRC_MAX_ROWS - 1;
        $blurb = "To chat with the BrowserPlus community, fire up your favorite IRC client and ";
        $blurb .= "head on over to <tt>#browserplus</tt> on <tt>freenode</tt>.";
        $nav = l("&laquo; Older", "?id={$first_id}", $first_id > 0) . " | " . l("Current", "/discuss/", $id != $max_id) . " | " . l("Newer &raquo;", "?id={$next_id}", $last_id < $max_id);
    }
}
$cfg = array("show_long_date" => false, "top_nav" => $nav, "bot_nav" => $nav);
if ($in_search) {
    $cfg["url_pat"] = "/discuss/?mid=%s";
    $cfg["url_key"] = "id";
}