Why do people visit the same websites day after day? Well, there are a number of reasons, one may be that the website offers a tool that they use like a search engine, but for most repeat visitors, it is to see what's new on the site. News is one of the most popular items on the web these days and a website with constantly updated news has a much better chance of attracting a return audience. Also, search engine spyders love content that changes, if your site has a news feed that the spyders can read, they are far more likely to come back sooner and more often.
So, how do I get spyder readable news on my site, you might ask. Well, it's actually pretty simple:
Download the PHP file HERE and unzip it.
Here is the text you place on your webpage.
By default, the feed will format like your website, but if you want to do special formatting you can create 2 new classes in your CSS file. Itemtitle will affect how the clickable news headline will appear and itemdescription will affect the news snippet, for example:
.itemtitle {text-align:center;font-size:14px;font-weight:bold} .itemtitle a{color:red;text-decoration:none}, would cause your headlines to be
14 pixels, bold, red and with no underline
The other item that can be edited is the maximum number of articles for the feed. By default it is set at 10, this can be edited by changing the 2-10's in the line
"if (count($rss_channel["items"]) > 10) {$NumberOfitems = 10;}"
to whatever number you would prefer.
A final note, on some hosting providers, the PHP will not work natively. You must add the following to your .htaccess file for it to work:
AddHandler application/x-httpd-php .htm .html (AddHandler application/x-httpd-php5 .htm .html if PHP 5 is installed)
or if you do not have a .htaccess file, you can download this one, unzip it and upload it to the folder on your host server that contains your index or home page.
Another note: Some providers do not allow custom .htaccess, if that is your case and the PHP doesn't work, contact your web hosting companies support and tell them you need PHP working or get a host that doesn't limit you like Host Gator.
The last question people often ask about RSS feeds is, "where can I find one?". The Internet is full of them, you can go to one of the large generic providers like Topix.net or do a search for the topic you want a feed for and add the word "rss" to the end of your search, there are plenty out there. Here is an example of one for WebmasterWorld.com:
The Relevance and Value of DMOZ 2009
Merchants Reporting Authorize.Net Payment Gateway is Down
W3C Abandons XHTML2, Increases Resources for HTML5
Web Advertisers' Trade Associations Put Forward Self-Regulation
Bing Tests Real Time Twitter Search
"...when you search for these folks names in association with Twitter, you'll see their latest Tweets come up in real time on Bing's search results."
Online since June of 2000, ©2008 The Moishe Co.