Re: creating rss feeds - how do u do it?
"Bill Kearney" <[email protected]> Sat, 12 Nov 2005 22:40:32 -0500
| Newsgroups | gmane.network.syndication.rss.devel |
|---|---|
| Organization | http://www.ideaspace.net/users/wkearney/foaf.xrdf |
| Message-ID | <[email protected]> |
> I have been hand coding html pages for 8 or 9 years now. I prefer to
> hand code, because I am a programmer by nature, and it allows me to
> better understand what I am doing (and it helps me to keep the code
> clean cut).
If you've got database storage it's often a lot less headache to use that
for building your RSS feeds. That way you only have to learn the tedious
bits of XML and RSS requirements once for the code that generates the feed.
Not every time you're pressed for time and running amok with emacs. (he
says, from personal experience...)
> Currently, I work on a local Linux box to create my php pages.
> Internally we send text products to this Linux box, which has a cron
> that runs scripts to generate a several of my php pages (or at least
> the data used in the php pages). As part of that cron, it then uploads
> the updated files to our internet server.
Sounds about right.
> That's also how I'm creating my RSS files which I am now playing with.
> I'm still trying to understand the relationship between RSS, XML, etc.
> If I understand it correctly, all RSS files are XML, but not all XML
> are RSS. Essentially RSS files are a subset of XML.
Well, not really. XML is XML. It's got it's own rules most commonly
recognized under the concept of being 'well formed'. Having all the angle
brackets match up and following a few rules about encoding certain
characters (5 specifically "&',<?)
> The content in each of these files could be grabbed using PHP. Can I
> use PHP to create a rss file? The file would then have a php extension
> - would that cause problems for rss readers?
Nope, URL extensions make no difference in ANY readers. It's the MIME type
you want to set properly; as 'application/rss+xml'.
> With the dynamic nature of rss feeds, how do most of you create the feed?
If you're already savvy with cron then how about using PHP from within a
cron job to dump the data right into static files? No sense using a dynamic
page on the server unless you've got live data that can't be generated ahead
of time as a static file. Plenty of sites do it this way. MovableType
blogs are almost entirely statically served. The script dump everything
through templates and then out to static files. Much quicker web serving
with no added dynamic code on the server (not that PHP's all that demanding
for most simple stuff).
Hope this helps.
-Bill Kearney
Syndic8.com
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/rss-dev/
<*> To unsubscribe from this group, send an email to:
[email protected]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/