Abe Hassan ([info]burr86) wrote in [info]changelog,
@ 2007-01-14 07:23:00
Previous Entry  Add to memories!  Tell a Friend!  Next Entry
[livejournal] r10062: Add support for RSS/Atom feeds of a jour...
Committer: ahassan
Add support for RSS/Atom feeds of a journal filtered by tag. Takes the same input as regular tags, as:

.../data/rss?tag=tagname
.../data/rss?tag=tag1,tag2

(When rendering a user journal, we build up the tagids *before* we call make_feed, so it's available to us. All we had to do was to make use of it.)

Whitaker, David, Artur: Three lines. I win. :)


U   trunk/cgi-bin/LJ/User.pm
U   trunk/cgi-bin/ljfeed.pl
Modified: trunk/cgi-bin/LJ/User.pm
===================================================================
--- trunk/cgi-bin/LJ/User.pm	2007-01-13 02:41:28 UTC (rev 10061)
+++ trunk/cgi-bin/LJ/User.pm	2007-01-14 07:23:35 UTC (rev 10062)
@@ -5688,9 +5688,9 @@
         return $error->("Sorry, the tag system is currently disabled.", "404 Not Found")
             if $LJ::DISABLED{tags};
 
-        # throw an error for S1, but only on non-rename accounts.
+        # throw an error if we're rendering in S1, but not for renamed accounts
         return $error->("Sorry, tag filtering is not supported within S1 styles.", "404 Not Found")
-            if $stylesys == 1 && $u->{journaltype} ne 'R';
+            if $stylesys == 1 && $view ne 'data' && $u->{journaltype} ne 'R';
 
         # overwrite any tags that exist
         $opts->{tags} = [];

Modified: trunk/cgi-bin/ljfeed.pl
===================================================================
--- trunk/cgi-bin/ljfeed.pl	2007-01-13 02:41:28 UTC (rev 10061)
+++ trunk/cgi-bin/ljfeed.pl	2007-01-14 07:23:35 UTC (rev 10062)
@@ -78,6 +78,7 @@
         'userid' => $u->{'userid'},
         'itemshow' => 25,
         'order' => "logtime",
+        'tagids' => $opts->{tagids},
         'itemids' => \@itemids,
         'friendsview' => 1,           # this returns rlogtimes
         'dateformat' => "S2",         # S2 format time format is easier



(Post a new comment)


[info]daveman692
2007-01-14 08:24 am UTC (link)
Wow, that means $66.66 per line ($200 bounty / 3 lines). Send me your address and I'll mail a check once it is live!

(Reply to this)(Thread)


[info]daveman692
2007-01-14 08:36 am UTC (link)
Well actually $100 per line since one line is a comment.

(Reply to this)(Parent)


[info]jemmix
2007-01-14 08:54 am UTC (link)
Thanks for doing that!

(Reply to this)


[info]kunzite1
2007-01-14 12:50 pm UTC (link)
this enhancement is made of win.

(Reply to this)(Thread)


[info]matgb
2007-01-17 01:21 am UTC (link)
Yess. One of my favourite WP features now also on LJ. Now all we need is to be able to syndicate our tags on here directly without the feedburner trick.

(Reply to this)(Parent)


[info]decadence1
2007-01-15 07:07 am UTC (link)
Let's have babies, plz.

(Reply to this)


Create an Account
Forgot your login?
Login w/ OpenID
English • Español • Deutsch • Русский…