Wrong title parsing
Sam Ruby
rubys at intertwingly.net
Tue Aug 26 09:32:22 EST 2008
Felipe Contreras wrote:
> On Sun, Aug 24, 2008 at 6:05 PM, Christopher Armstrong
> <radix at twistedmatrix.com> wrote:
>> On Sun, Aug 24, 2008 at 6:38 AM, Felipe Contreras
>> <felipe.contreras at gmail.com> wrote:
>>> Hi,
>>>
>>> The way the title is parsed is wrong. Instead of taking the title tag
>>> of title you are taking any 'title' argument or tag, for example:
>>>
>>> <media:content url="http://a.wordpress.com/avatar/felipec-128.jpg"
>>> medium="image">
>>> <media:title type="html">FelipeC</media:title>
>>> </media:content>
>>>
>>> You can see that in http://planet-im.com/.
>>>
>>> Anytime an image is included the title of the post is wrongly using
>>> the title of the image.
>> Hi Felipe. This is because Wordpress generates invalid XML; you may
>> notice that the default XML namespace is not defined in that feed.
>> Planet doesn't deal well with this, but apparently Venus knows how to
>> work around it. Venus is a fork of Planet which is (perhaps) better
>> maintained. I haven't actually tried it yet, so my planet still has
>> this bug, but I plan to soon.
>>
>> Unfortunately, it has a web site that's about as crappy as Planet's ;-)
>>
>> http://www.intertwingly.net/code/venus/
>
> Is that required?
> http://validator.w3.org/feed/check.cgi?url=http%3A%2F%2Ffelipec.wordpress.com%2Ffeed
The feed is correct, the version of the feedvalidator contained in
planet 2.0 has a bug. Venus is based on a more recent version of the
feedvalidator.
> Anyway, I took planet-im as a basis and using this code [1] I have the
> same functionality that planetplanet is supposed to provide in 160
> lines of code (including the template). Well only the html, but I
> guess the rest is going to be equally easy.
>
> [1] http://www.igvita.com/2007/03/22/agile-rss-aggregator-in-ruby/
- Sam Ruby
More information about the devel
mailing list