<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: How can SimplePie&#8217;s API improve?</title>
	<atom:link href="http://simplepie.org/blog/2008/03/14/how-can-simplepies-api-improve/feed/" rel="self" type="application/rss+xml" />
	<link>http://simplepie.org/blog/2008/03/14/how-can-simplepies-api-improve/</link>
	<description>Behind the scenes of SimplePie development.</description>
	<lastBuildDate>Sun, 12 Feb 2012 16:47:26 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.4-beta4-20825</generator>
	<item>
		<title>By: Ryan McCue</title>
		<link>http://simplepie.org/blog/2008/03/14/how-can-simplepies-api-improve/comment-page-1/#comment-9643</link>
		<dc:creator>Ryan McCue</dc:creator>
		<pubDate>Sun, 16 Mar 2008 08:28:11 +0000</pubDate>
		<guid isPermaLink="false">http://simplepie.org/blog/2008/03/14/how-can-simplepies-api-improve/#comment-9643</guid>
		<description>I&#039;d like to see some way of intercepting the DB cache writes, for example, to have a moderation queue of items from each feed (one of our requested features).

&lt;blockquote&gt;I don?t particularly think that any aggregator needs to actually know the specific status code.&lt;/blockquote&gt;
I have to agree with Geoffery on this one. I think that the aggregator should just check to see if subscribe_url() equals the old one and if not, to cache the new one instead. They shouldn&#039;t have to check status codes themselves, unless they want to.

&lt;blockquote&gt;What is SimplePie all about? What is it best at? SP is best at making RSS feeds easy to get, parse, and display. Anything else, like caching files, sanitizing html, could be done by other modules that are the already best in their class. SP should just be the glue that binds them all together. IMHO.&lt;/blockquote&gt;
Agreed also. As another example, the social sharing URLs should be in a module, as most people aren&#039;t going to use them.</description>
		<content:encoded><![CDATA[<p>I&#8217;d like to see some way of intercepting the DB cache writes, for example, to have a moderation queue of items from each feed (one of our requested features).</p>
<blockquote><p>I don?t particularly think that any aggregator needs to actually know the specific status code.</p></blockquote>
<p>I have to agree with Geoffery on this one. I think that the aggregator should just check to see if subscribe_url() equals the old one and if not, to cache the new one instead. They shouldn&#8217;t have to check status codes themselves, unless they want to.</p>
<blockquote><p>What is SimplePie all about? What is it best at? SP is best at making RSS feeds easy to get, parse, and display. Anything else, like caching files, sanitizing html, could be done by other modules that are the already best in their class. SP should just be the glue that binds them all together. IMHO.</p></blockquote>
<p>Agreed also. As another example, the social sharing URLs should be in a module, as most people aren&#8217;t going to use them.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ryan Parman</title>
		<link>http://simplepie.org/blog/2008/03/14/how-can-simplepies-api-improve/comment-page-1/#comment-9642</link>
		<dc:creator>Ryan Parman</dc:creator>
		<pubDate>Sat, 15 Mar 2008 21:46:14 +0000</pubDate>
		<guid isPermaLink="false">http://simplepie.org/blog/2008/03/14/how-can-simplepies-api-improve/#comment-9642</guid>
		<description>Great feedback so far guys. We&#039;re not making any definitive decisions here just yet, but we&#039;re eager to hear back from more people about what, in your opinion, could be better or easier. Keep it coming! :)</description>
		<content:encoded><![CDATA[<p>Great feedback so far guys. We&#8217;re not making any definitive decisions here just yet, but we&#8217;re eager to hear back from more people about what, in your opinion, could be better or easier. Keep it coming! <img src='http://simplepie.org/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Geoffrey Sneddon</title>
		<link>http://simplepie.org/blog/2008/03/14/how-can-simplepies-api-improve/comment-page-1/#comment-9636</link>
		<dc:creator>Geoffrey Sneddon</dc:creator>
		<pubDate>Sat, 15 Mar 2008 14:50:38 +0000</pubDate>
		<guid isPermaLink="false">http://simplepie.org/blog/2008/03/14/how-can-simplepies-api-improve/#comment-9636</guid>
		<description>&lt;blockquote cite=&quot;&quot;&gt;&lt;p&gt;I?ve been thinking about the kinds of things that would make things easier for me and how we could bundle them as on-demand ?helpers? instead of necessarily building them into the core (like how our Internationalized Domain Name support is separate).&lt;/p&gt;&lt;/blockquote&gt;

FWIW, there won&#039;t be any need to keep the IDNA support in SP1.2, as the new IRI class (which provides all kinds of things dealing with IRIs all over the place).

&lt;blockquote cite=&quot;&quot;&gt;&lt;p&gt;The first (very simple) thing that comes to mind is a function that that shortens text (e.g. titles and descriptions).&lt;/p&gt;&lt;/blockquote&gt;

I&#039;m sure you, Ryan, know my opinion of this well: The only way to properly shorten HTML is to use an HTML parser (as we end up needed all kinds of mad things to deal with fallback content within object elements, for example).

&lt;blockquote cite=&quot;&quot;&gt;&lt;p&gt;Perhaps people parsing thousands of feeds might like to have (or contribute) their parsing scripts and/or cron jobs?&lt;/p&gt;&lt;/blockquote&gt;

I still don&#039;t really want to even really suggest using SP for such things: it really isn&#039;t suited to such huge numbers of feeds, due to the speed of PHP. Even something like Python (and &lt;a href=&quot;http://feedparser.org&quot; rel=&quot;nofollow&quot;&gt;Universal Feed Parser&lt;/a&gt;) is far more suited (IMO, by then it is quick enough for the network to be the bottleneck, unless you have an insanely quick connection).

&lt;blockquote cite=&quot;&quot;&gt;Perhaps people building feed aggregators would like to see improved HTTP status code messages to know whether they should update a feed URL in a database&lt;/p&gt;&lt;/blockquote&gt;

To fully do this, we need also to be able give a new SimplePie::subscribe_url() ? or to return null when we get 410 Gone. This is certainly something I want to see, but implementing this is far from simple: the current HTTP support can&#039;t cope with it, and nor can most PHP implementations. I don&#039;t really want to even attempt to try and redo the support until http-parsing has at least a -01 draft published. I don&#039;t particularly think that any aggregator needs to actually know the specific status code. Of course, if anyone thinks otherwise, feel free to say.

&lt;blockquote cite=&quot;#comment-9635&quot;&gt;&lt;p&gt;Why do everything from scratch when its already been done better ages ago? This is what open source is or should be all about isn?t it? Take the best code from here, the best code from there?&lt;/p&gt;&lt;/blockquote&gt;

Part of the reason why so much code was written for SP itself was that although it is easy to find code to do such things, most of it really doesn&#039;t work very well: for example, the only decent working HTML sanitiser was kses; HTTP tends to be very very badly implemented (SP&#039;s is far from brilliant, too). The only other thing is the desire for SP to work without needing to have loads of things thrown together to get some basic parsing.

&lt;blockquote cite=&quot;#comment-9635&quot;&gt;&lt;p&gt;But the sanitize class tries to do so many things you cant just override it easily as far as I can tell.&lt;/p&gt;&lt;/blockquote&gt;

Splitting it up would be a huge effort, though. Part of me would much prefer to just wait until SP2 before having it split up? Though if someone else splits it up I won&#039;t complain :P</description>
		<content:encoded><![CDATA[<blockquote cite=""><p>I?ve been thinking about the kinds of things that would make things easier for me and how we could bundle them as on-demand ?helpers? instead of necessarily building them into the core (like how our Internationalized Domain Name support is separate).</p>
</blockquote>
<p>FWIW, there won&#8217;t be any need to keep the IDNA support in SP1.2, as the new IRI class (which provides all kinds of things dealing with IRIs all over the place).</p>
<blockquote cite=""><p>The first (very simple) thing that comes to mind is a function that that shortens text (e.g. titles and descriptions).</p>
</blockquote>
<p>I&#8217;m sure you, Ryan, know my opinion of this well: The only way to properly shorten HTML is to use an HTML parser (as we end up needed all kinds of mad things to deal with fallback content within object elements, for example).</p>
<blockquote cite=""><p>Perhaps people parsing thousands of feeds might like to have (or contribute) their parsing scripts and/or cron jobs?</p>
</blockquote>
<p>I still don&#8217;t really want to even really suggest using SP for such things: it really isn&#8217;t suited to such huge numbers of feeds, due to the speed of PHP. Even something like Python (and <a href="http://feedparser.org" rel="nofollow">Universal Feed Parser</a>) is far more suited (IMO, by then it is quick enough for the network to be the bottleneck, unless you have an insanely quick connection).</p>
<blockquote cite=""><p>Perhaps people building feed aggregators would like to see improved HTTP status code messages to know whether they should update a feed URL in a database</p></blockquote>
<p>To fully do this, we need also to be able give a new SimplePie::subscribe_url() ? or to return null when we get 410 Gone. This is certainly something I want to see, but implementing this is far from simple: the current HTTP support can&#8217;t cope with it, and nor can most PHP implementations. I don&#8217;t really want to even attempt to try and redo the support until http-parsing has at least a -01 draft published. I don&#8217;t particularly think that any aggregator needs to actually know the specific status code. Of course, if anyone thinks otherwise, feel free to say.</p>
<blockquote cite="#comment-9635"><p>Why do everything from scratch when its already been done better ages ago? This is what open source is or should be all about isn?t it? Take the best code from here, the best code from there?</p>
</blockquote>
<p>Part of the reason why so much code was written for SP itself was that although it is easy to find code to do such things, most of it really doesn&#8217;t work very well: for example, the only decent working HTML sanitiser was kses; HTTP tends to be very very badly implemented (SP&#8217;s is far from brilliant, too). The only other thing is the desire for SP to work without needing to have loads of things thrown together to get some basic parsing.</p>
<blockquote cite="#comment-9635"><p>But the sanitize class tries to do so many things you cant just override it easily as far as I can tell.</p>
</blockquote>
<p>Splitting it up would be a huge effort, though. Part of me would much prefer to just wait until SP2 before having it split up? Though if someone else splits it up I won&#8217;t complain <img src='http://simplepie.org/blog/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Michael Shipley</title>
		<link>http://simplepie.org/blog/2008/03/14/how-can-simplepies-api-improve/comment-page-1/#comment-9635</link>
		<dc:creator>Michael Shipley</dc:creator>
		<pubDate>Sat, 15 Mar 2008 05:13:06 +0000</pubDate>
		<guid isPermaLink="false">http://simplepie.org/blog/2008/03/14/how-can-simplepies-api-improve/#comment-9635</guid>
		<description>Anything that gives the SP user more control and granularity over how SP does it&#039;s thing is a very good idea if you ask me. One example is the &quot;set_image_handler&quot; function. I&#039;d like to see that put in a separate class so I could have more control over it because right now its seems to be an all or nothing proposition. All the images in an item are fetched and cached when you do a &quot;get_content&quot; even if you end up not displaying most of items. I&#039;m actually forced to write my own custom image caching right now because of the lack of control. I can&#039;t just override the image caching class because -- there is none. 

So yes I agree completely that modularization is the way to go. Let the user decide what pieces of the &#039;Pie they want so they can mix and match or at least control it better. I think SP should focus on being more of a framework that allows you to easily plug in already best of breed modules dont you think? Why do everything from scratch when its already been done better ages ago? This is what open source is or should be all about isn&#039;t it? Take the best code from here, the best code from there? Like the emperor said: &quot;Focus! It makes you strongga! Muahaha!&quot; Do one thing and do it well as they say. For instance, I prefer htmlpurifier to SP&#039;s built in html sanitizer. But the sanitize class tries to do so many things you cant just override it easily as far as I can tell. 

What is SimplePie all about? What is it best at? SP is best at making RSS feeds easy to get, parse, and display. Anything else, like caching files, sanitizing html, could be done by other modules that are the already best in their class. SP should just be the glue that binds them all together. IMHO.</description>
		<content:encoded><![CDATA[<p>Anything that gives the SP user more control and granularity over how SP does it&#8217;s thing is a very good idea if you ask me. One example is the &#8220;set_image_handler&#8221; function. I&#8217;d like to see that put in a separate class so I could have more control over it because right now its seems to be an all or nothing proposition. All the images in an item are fetched and cached when you do a &#8220;get_content&#8221; even if you end up not displaying most of items. I&#8217;m actually forced to write my own custom image caching right now because of the lack of control. I can&#8217;t just override the image caching class because &#8212; there is none. </p>
<p>So yes I agree completely that modularization is the way to go. Let the user decide what pieces of the &#8216;Pie they want so they can mix and match or at least control it better. I think SP should focus on being more of a framework that allows you to easily plug in already best of breed modules dont you think? Why do everything from scratch when its already been done better ages ago? This is what open source is or should be all about isn&#8217;t it? Take the best code from here, the best code from there? Like the emperor said: &#8220;Focus! It makes you strongga! Muahaha!&#8221; Do one thing and do it well as they say. For instance, I prefer htmlpurifier to SP&#8217;s built in html sanitizer. But the sanitize class tries to do so many things you cant just override it easily as far as I can tell. </p>
<p>What is SimplePie all about? What is it best at? SP is best at making RSS feeds easy to get, parse, and display. Anything else, like caching files, sanitizing html, could be done by other modules that are the already best in their class. SP should just be the glue that binds them all together. IMHO.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

