Link Page Update

I just updated the script behind the links template in WordPress, so instead of pulling from the "blogroll" table which I rarely maintain in WP, it now pulls from my Gregarious Feed Reader subscriptions - only the ones that I haven't marked private (which aren't many - just the ego feeds which aren't really useful to anyone else). So, if you want to know the sites that I read *every day*, check out the new links page. If your personal weblog is not on there, don't feel bad - I'm constantly adding and deleting feeds as I focus on different things and trying to keep normal blogs to a minimum. If you notice any really good Mobile feeds that I'm not keeping up with though, definitely send them my way.

In case you happen to have Gregarious installed on the same server as your WordPress installation, here's the script (it's not particularly exciting or difficult, but I figured I'd help save someone a few minutes):

Template Name: Links
<?php get_header(); ?>
<div id="content">
    <div class="entrybody">
    $db = new PDO('mysql:host=;dbname=feedsdbname', 'username', 'password');
    $results = $db->query('SELECT name, title, siteurl FROM channels, folders where and mode=1 order by folders.position');
        $oldname = '';
        foreach($results->fetchAll() as $row){
                $name = $row['name'];
                if($name != $oldname){
                                echo '</ul>' . "n";
                        echo '<h2>' . $name . '</h2>' . "n";
                        echo '<ul>' . "n";
                        $oldname = $name;
                echo '<li><a href="' . $row['siteurl'] . '">' . $row['title'] . '</a></li>' . "n";
        echo '</ul>' . "n";
<?php get_footer(); ?>


< Previous         Next >