Ejemplo n.º 1
0
<?php

include_once "../../includes/easyparliament/init.php";
include_once INCLUDESPATH . "easyparliament/commentreportlist.php";
$this_page = "admin_trackbacks";
$PAGE->page_start();
$PAGE->stripe_start();
$TRACKBACK = new TRACKBACK();
$TRACKBACK->display('recent', array('num' => 30));
$menu = $PAGE->admin_menu();
$PAGE->stripe_end(array(array('type' => 'html', 'content' => $menu)));
$PAGE->page_end();
Ejemplo n.º 2
0
        $PAGE->stripe_start('side', 'comments');
        $COMMENTLIST = new COMMENTLIST();
        $args['user_id'] = get_http_var('u');
        $args['epobject_id'] = $WHALLLIST->epobject_id();
        $COMMENTLIST->display('ep', $args);
        $PAGE->stripe_end();
        $PAGE->stripe_start('side', 'addcomment');
        $commendata = array('epobject_id' => $WHALLLIST->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();
        }
        $TRACKBACK = new TRACKBACK();
        $TRACKBACK->display('epobject_id', $commendata);
    }
} else {
    // No date or debate id. Show recent years with debates on.
    $this_page = "whallfront";
    $PAGE->page_start();
    $PAGE->stripe_start();
    ?>
				<h4>Busiest Westminster Hall debates from the most recent week</h4>
<?php 
    $WHALLLIST = new WHALLLIST();
    $WHALLLIST->display('biggest_debates', array('days' => 7, 'num' => 20));
    $rssurl = $DATA->page_metadata($this_page, 'rss');
    $PAGE->stripe_end(array(array('type' => 'nextprev'), array('type' => 'include', 'content' => 'calendar_whalldebates'), array('type' => 'include', 'content' => "whalldebates"), array('type' => 'html', 'content' => '<div class="block">
<h4>RSS feed</h4>
Ejemplo n.º 3
0
<?php

// This code based on stuff from http://wordpress.org/
include_once "../../includes/easyparliament/init.php";
$this_page = 'trackback';
// The gid is the gid of the thing being trackedback to.
$epobject_id = get_http_var('e');
// eg, '3424'
$url = get_http_var('url');
$blog_name = get_http_var('blog_name');
$title = get_http_var('title');
$excerpt = get_http_var('excerpt');
if ($title == '' && $url == '' && $blog_name == '') {
    // If it doesn't look like a trackback at all...
    // We could/should redirect to the URL of this particular item.
    // Word Press does this:
    //header('Location: ' . get_permalink($gid));
    // But for now we're just getting the hell outta here:
    exit;
}
if (strlen('' . $epobject_id) && empty($HTTP_GET_VARS['__mode']) && strlen('' . $url)) {
    header('Content-Type: text/xml');
    $trackbackdata = array('epobject_id' => $epobject_id, 'url' => $url, 'blog_name' => $blog_name, 'title' => $title, 'excerpt' => $excerpt, 'source_ip' => $HTTP_SERVER_VARS['REMOTE_ADDR']);
    $TRACKBACK = new TRACKBACK();
    $TRACKBACK->add($trackbackdata);
}