Tech Setup for Developers
Setup your site to use Feed.Us
You know how user documentation has all these explanations and analogies and hand-holding and stuff? And you’re banging your head against the desk screaming “Get to the point!”
Well, Feed.Us totally gets you, so here’s an honest-to-goodness stripped-down tech sheet. Bon appetit! And if you have any questions, feel free to Ask John.
Feed.Us works like this: (click the image for a larger version)
Feed.Us Installation and Setup
Well, there really isn’t any. No fancy installation process necessary.
Just add one file to your server (or two if you're running ASP), add a directory on your hosting account and then paste Feed.Us scripts onto your site files where you want your content to display on your site.
Also, make sure you've got content already loaded into Feed.Us. It'll make the setup process smoother.
1 On the host server, create a directory called "CachedWebContent" and give it with read, write, and web access. (More on creating directories here.)
2 Download the "Grabber" file(s) for your server. You can tweak the code to optimize it for your use.
There's a "Grabber" file for each platform type (PHP, ASP, .Net, RoR, etc).
Download the files here (you'll need to be logged in).
3 Put your Grabber file(s) on your server.
You can put the grabbers on whatever folder is going to contain the content. You can put them in the root folder and each of the other folders of your site (/about, etc).
But it's easier to just have the Grabber file in the root folder. Then when you have Feed.Us scripts in sub folders, you'll need to point to that root folder (use ../FeedUsGrabber.php etc).
(FYI, ASP uses 2 Grabbers)
4 The final step is to create Feed.Us scripts:
Login to Feed.Us and proceed to the "Export" tab. The first page is our "Scriptomatic".
The Scriptomatic is a series of dropdowns that helps you choose the content and create scripts that you will add to your site files. You can filter your content (by type, categories, number of items, date etc) then choose your platform (PHP, etc) and a Layout.
Here's a view of the Scriptomatic:
5 Choose your options via dropdowns:
Source is what content you are trying to show. You can choose one article (example: your "about" page) or a group of articles based on category. Or all the articles.
Sort: if you are choosing more than one article, you can sort them by date, author name, etc.
Layouts refer to the XSL Layout that is used to display fields and also CSS tags. Feed.Us comes preloaded with default XSL Layouts that use a variety of fields of content. Using Layouts, you can choose to display a full article with all fields or just one article with just the body field. Also - XSL layouts can include HTML or CSS/XHTML within them, allowing for formatting.
Just choose "Title and Body" for a basic content view that uses the Title and the Body of the post.
Platform is where you select which software achitecture you're using on your site. PHP, ASP, etc.
Click the button at the bottom that says "Preview & Get Code"
Feed.Us will then load the scripts that are needed to display your content on your site, along with an associated URL for the code and a preview of your content. It looks like this:
8 Embed Your Code:
Those two lines of code include the Feed.Us secure, unique URL that is associated with this item. The PHP code looks like this (image below)
You place that code into your ASP or PHP file exactly where you want the content to show. Typically where your the title and body of your page would normally go.
Then upload your file to the server and you've done it!
Note: You can set this up ahead of time. For example, say you've got an author who will be writing a Recipe of the Month. You can create twelve substitute documents, one for each month, and paste the code in where appropriate. Then when the user writes the actual content and clicks Publish, the content will just drop into the site where it is supposed to go, no fuss, no muss.
Problems? Questions? Don't be afraid to try our Ask John feature.
Note: Rails and .Net are different - they use controllers - but not more difficult.