[geeklog-devtalk] Syndication Re-write
Michael Jervis
mike at fuckingbrit.com
Wed Jan 26 02:49:11 EST 2005
>I've incorporated your patches into CVS now.
Excellent.
>So what do we do with the existing feeds?
Yeah I think that's best.
>I would need a table mapping the old names to the new ones then:
old new
'rss' -> 'RSS-0.91' (has to be numerical for the < comparison to be
reliable)
'rss2' -> 'RSS-2.0'
'atom' -> 'Atom-0.3'
'rdf' -> 'RDF-1.0'
However, with no version, rss will be served with RSS 0.9x anyway. Atom
version makes no difference, neither does RDF but to be future compatible...
>You didn't finish that, it seems. I see that FeedParserFactory::reader
accepts a >character set as the second parameter now but doesn't use it.
I was rushing to get off to Scotland on business, the item is also used by
FeedParserFactory::_findFeed, but reader forgets to pass it on:
/**
* Method to get a feed handler class.
*
* This function takes a url, fetches it, parses it, and thus figures
out
* what type of feed parser to return, with the contents all parsed for
* your viewing pleasure.
*
* @access public
* @param string $url The url to a feed type to syndicate.
* @param string $targetformat The target format for the encoding,
* see:
*
http://project.geeklog.net/tracker/index.php?func=detail&aid=301&group_id=6&
atid=105
*/
function reader( $url, $targetformat='' )
{
if( $fp = $this->_getFeed( $url ) )
{
return $this->_findFeed( $fp, $targetformat );
} else {
return false;
}
}
>I didn't realise that it was an established license you were using there.
I could have sworn I'd noted in the headers it was ZLIB, but I guess I
didn't. Perhaps that should be noted. Forstall a few questions.
/***************************************************************************
*/
/* Copyright (c) 2004 Michael Jervis (mike at fuckingbrit.com)
*/
/*
*/
/* This software is licensed under the terms of the ZLIB License:
*/
/*
*/
/* This software is provided 'as-is', without any express or implied
*/
/* warranty. In no event will the authors be held liable for any damages
*/
/* arising from the use of this software.
*/
/*
*/
/* Permission is granted to anyone to use this software for any purpose,
*/
/* including commercial applications, and to alter it and redistribute it
*/
/* freely, subject to the following restrictions:
*/
/*
*/
/* 1. The origin of this software must not be misrepresented; you must
not */
/* claim that you wrote the original software. If you use this
software */
/* in a product, an acknowledgment in the product documentation would
be*/
/* appreciated but is not required.
*/
/*
*/
/* 2. Altered source versions must be plainly marked as such, and must
not */
/* be misrepresented as being the original software.
*/
/*
*/
/* 3. This notice may not be removed or altered from any source
*/
/* distribution.
*/
/***************************************************************************
*/
Thanks for integrating it,
Michael
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3030 bytes
Desc: not available
Url : <http://eight.pairlist.net/pipermail/geeklog-devtalk/attachments/20050126/05bd1a38/attachment.bin>
More information about the geeklog-devtalk
mailing list