<?php
/*
* buzzword
* Copyright (c) 2003 Jon Tai
*
* $Id: index.php 20 2004-04-27 23:53:26Z brad $
*
* This file is part of buzzword.
*
* buzzword is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* buzzword is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with buzzword; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
require_once './config.inc';
include_once '../includes/header.inc';
// refresh cache
$subscriptions = get_planet_subscriptions();
foreach ($subscriptions as $subscription)
$subscription->fetch_feed();
?>
<table cellpadding="0" cellspacing="0" border="0" width="100%">
<tr>
<td id="content">
<?php
$lastdate = 0;
$entries = get_planet_entries_by_date(0, time() + (3600 * 24), 20); // 24 hrs in advance, to account for GMT
foreach ($entries as $entry) {
if ($lastdate != date('Y-m-d', $entry->created)) {
$lastdate = date('Y-m-d', $entry->created);
echo '<h1>'.$entry->get_display_date_created()."</h1>\n";
}
?>
<div class="content-container">
<h2><a href="subscription.php?s=<?php echo $entry->parent->subscription_key; ?>"><?php
echo $entry->parent->get_display_short_title(); ?></a>: <a
href="<?php echo $entry->trackback_url; ?>"><?php echo $entry->get_display_short_title(); ?></a></h2>
<?php
if ($entry->parent->icon != 0 && $entry->parent->icon->exists()) {
?>
<div class="planet-icon"><a href="subscription.php?s=<?php echo $entry->parent->subscription_key; ?>"><img
src="../gallery/thumb.php?i=<?php echo $entry->parent->icon->image_key; ?>" <?php echo $entry->parent->icon->get_alt(); ?>
border="0" <?php echo $entry->parent->icon->get_thumb_size(); ?>></a></div>
<?php
}
?>
<p><?php echo $entry->get_display_body(); ?></p>
<span class="planet-date">
<?php
echo '<a href="'.$entry->trackback_url.'">(';
echo $entry->get_display_date_created().' ';
echo $entry->get_display_time_created().')</a>';
?></span>
</div>
<?php
}
?>
</td>
<td id="sidebar">
<h1>subscriptions</h1>
<div class="sidebar-container">
<p>
<?php
echo get_sidebar_planet_subscriptions();
?>
</p>
</div>
<?php if (defined('ADMIN_LOGGED_IN')) { ?>
<h1>administration</h1>
<div class="sidebar-container">
<p>
<a href="newsubscription.php">new subscription</a><br>
<a href="../admin/preferences.php">preferences</a><br>
<a href="../admin/index.php?admin-logout=1">log out</a><br>
</p>
</div>
<?php } ?>
</td>
</tr>
</table>
<?php
include_once '../includes/footer.inc';
?>