Syndication links question

Creating and modifying plugins.
Post Reply
Brian1969
Regular
Posts: 78
Joined: Tue Mar 22, 2005 7:03 pm
Contact:

Syndication links question

Post by Brian1969 »

Hi,

Quick question, and it's not a big deal, really, but I was wondering if there was a way to expand the Syndication plugin to include other web-based reader links.

For example, I know that Feedburner is on the list, but is there a way to put a link to Yahoo, AOL, Newsgator, or any of the other services?

Besides creating a html plugin, that is? Maybe someone could update the plugin to accept more RSS syndication links?

Thanks!
Brian
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Syndication links question

Post by garvinhicking »

Hi!

The syndication plugin itself does not list those; but you could either patch the plugin and create your own one, or you could just create a HTML nugget with the appropriate links to other web-based readers, which is IMHO the best solution.

Of course the main plugin could also be patched to include other links as well, but we should make a good choice of which ones to include. Since feedburner has very special features it'S on the list, so other services should also have unique features apart from just "viewing" RSS feeds? Because in that case I'd really suggest to just place a HTML nugget.

HTH,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Euclidean
Posts: 4
Joined: Fri May 19, 2006 3:54 pm

Post by Euclidean »

I just got done modifying my syndication plugin to successfully add the google and yahoo buttons.

The file I modified was /includes/plugin_internal.inc.php

Of course, make sure you save a copy for good posterity. Then I went to the Add Google Button Page where I typed in the URL of my RSS 2.0 feed which for my installation was "http://www.endlessbanter.com/index.php? ... index.rss2". I used the same URL for the Add to Yahoo Button Page. Both of these pages will give you html snippets that you can add to your plugin_internal.inc.php file

In the php file you can do the following to successfully add the buttons:
1. Find "if (serendipity_db_bool($this->get_config('show_0.91', true)))"
2. Add this before the string you searched for

Code: Select all

?>
       <div style="padding-bottom: 4px;">
		GOOGLE CODE SNIPPET
		<br />
		YAHOO CODE SNIPPET
        </div>

<?php
Ultimately your file should resemble the following:

Code: Select all

    function generate_content(&$title)
    {
        global $serendipity;

        $title = $this->title;
?>
        <div style="padding-bottom: 4px;">
		GOOGLE CODE SNIPPET
		<br />
		YAHOO CODE SNIPPET
        </div>

<?php

        if (serendipity_db_bool($this->get_config('show_0.91', true))) {
In order to test it I created a my yahoo and google reader account and all worked. Hope this helps.
Brian1969
Regular
Posts: 78
Joined: Tue Mar 22, 2005 7:03 pm
Contact:

Worked like a charm!

Post by Brian1969 »

Hey, thanks. That worked great!
Brian
Euclidean
Posts: 4
Joined: Fri May 19, 2006 3:54 pm

Post by Euclidean »

your welcome glad i could help
Post Reply