Beispiel #1
0
$committee = new StandingCommittee($session, $bill);
if ($bill_id && !$id) {
    $this_page = 'pbc_bill';
    $args = array('id' => $bill_id, 'title' => $bill, 'session' => $session);
    $committee->display('bill', $args);
} elseif ($bill_id && $id) {
    $this_page = 'pbc_clause';
    $args = array('gid' => $standingprefix . $id, 's' => get_http_var('s'), 'member_id' => get_http_var('m'), 'glossarise' => 1, 'sort' => 'regexp_replace', 'bill_id' => $bill_id, 'bill_title' => $bill, 'bill_session' => $session);
    $GLOSSARY = new GLOSSARY($args);
    # Why a global?
    if (preg_match('/speaker:(\\d+)/', get_http_var('s'), $mmm)) {
        $args['person_id'] = $mmm[1];
    }
    $result = $committee->display('gid', $args);
    /* This section below is shared between here and everywhere else - factor it out! */
    if ($committee->htype() == '12' || $committee->htype() == '13') {
        $PAGE->stripe_start('side', 'comments');
        $COMMENTLIST = new COMMENTLIST();
        $args['user_id'] = get_http_var('u');
        $args['epobject_id'] = $committee->epobject_id();
        $COMMENTLIST->display('ep', $args);
        $PAGE->stripe_end();
        $PAGE->stripe_start('side', 'addcomment');
        $commendata = array('epobject_id' => $committee->epobject_id(), 'gid' => get_http_var('id'), 'return_page' => $this_page);
        $PAGE->comment_form($commendata);
        if ($THEUSER->isloggedin()) {
            $sidebar = array(array('type' => 'include', 'content' => 'comment'));
            $PAGE->stripe_end($sidebar);
        } else {
            $PAGE->stripe_end();
        }