Page 1 of 1

Changing RSS Topic Title?

Posted: Wed Mar 21, 2007 2:22 pm
by MntlyNSane
Is there anyway to make the RSS Feed Display the following as the title:

[%catagory%] %Title%

Thanks in advance!

Re: Changing RSS Topic Title?

Posted: Wed Mar 21, 2007 2:38 pm
by garvinhicking
Hi!

You can edit that into the feed*.tpl files of your template, yes.

However, note that most RSS readers have support to display the categories in a seperate column already, and that you would duplicate the title in that case.

Best regards,
Garvin

Re: Changing RSS Topic Title?

Posted: Wed Mar 21, 2007 3:22 pm
by MntlyNSane
garvinhicking wrote: However, note that most RSS readers have support to display the categories in a seperate column already, and that you would duplicate the title in that case.
Garvin
I'm using the Google Reader, and I've checked all of my feeds and none display the category. In other feeds I subscribe to, I do see the [%cat%] layout (Fark for example) :?

Is there a different reader I can use to test?

Now forgive the n00b question, but I looked at my feed_2.0.tpl.php file in the templates_c directory, and can't make heads or tails of it. Where would I update this?

Re: Changing RSS Topic Title?

Posted: Wed Mar 21, 2007 3:33 pm
by garvinhicking
Hi!
I'm using the Google Reader, and I've checked all of my feeds and none display the category. In other feeds I subscribe to, I do see the [%cat%] layout (Fark for example) :?
Which URL is your feed, and which is the one of "Fark" (don't know what that is)? Maybe you'Ve subscribed to your RSS 0.91 feed instead of the 2.0 one...
Is there a different reader I can use to test?
I personally use the windows RSS Bandit client, which shows categories (also for my own s9y feed) as a column....
Now forgive the n00b question, but I looked at my feed_2.0.tpl.php file in the templates_c directory, and can't make heads or tails of it. Where would I update this?
No problem. First you need to look at the real file. :-D

It's in templates/nameofyourtemplate/feed_2.0.tpl - if your template does not have such a file, use the templates/default/feed_2.0.tpl file and copy it to your directory.

There you locate the <item> portion of the file. It's lin line 25 for me:

Code: Select all

<title>{$entry.feed_title}</title>
Now you can insert the category in the title by changing this to:

Code: Select all

<title>[{foreach from=$entry.categories item="cat"}{$cat.feed_category_name} {/foreach}] {$entry.feed_title}</title>
This would print each category name (if you assigned your entry to multiple categories) within the title of your feed. Save the file and you'Re done :)

Best regards
Garvin
[/code]

Re: Changing RSS Topic Title?

Posted: Wed Mar 21, 2007 4:31 pm
by MntlyNSane
garvinhicking wrote:Which URL is your feed, and which is the one of "Fark" (don't know what that is)? Maybe you'Ve subscribed to your RSS 0.91 feed instead of the 2.0 one...
I ended up subscribing to all my feeds to test it :lol:

Each had the same results
I personally use the windows RSS Bandit client, which shows categories (also for my own s9y feed) as a column....
Tried that, and the catagories do show up properly under Topics...hmmm
It's in templates/nameofyourtemplate/feed_2.0.tpl....etc
:lol:

Files did not exist, put them there and made the modifications, and it seems to work now. Thanks!

Overall the problem appears to be Google. Now it would be nice if the Google developers would fix the Reader to automatically display the catagory with :roll:

Thanks for all the help!

Posted: Mon Mar 26, 2007 9:34 pm
by judebert
Which URL is your feed, and which is the one of "Fark" (don't know what that is)? Maybe you'Ve subscribed to your RSS 0.91 feed instead of the 2.0 one...
OMG, you don't know about FARK? It's rude news. And image modification contests. Worth it just for the funny headlines.

Of course, it will suck up all your time. Garvin, you definitely should avoid it.