You are here: Documentation » SimplePie Live! » Requirements and Getting Started
Differences
This shows you the differences between two versions of the page.
live:setup:start [2013/04/27 09:58] tomrobert87 |
live:setup:start [2013/08/11 04:50] (current) rmccue old revision restored |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | California is a massive state with many people who are members of this well-known group, so it's likely that many people have questions as to how this could affect them. As of right now, it's not really known. There aren't really many details available on what could result from such a move. | + | ====== Requirements and Getting Started ====== |
- | The Supreme Court ruled in 2000 that it was okay for the Boy Scouts of America to discriminate against homosexuals due to their freedom of association. Nonetheless, this new approach of going after their tax exempt status might have a different outcome. The group famously considered lifting their ban on gay members earlier this year, but their decision has been delayed—and understandably so. This is a huge decision to make regardless of how much of a no-brainer it might seem to the rest of the country. [http://vienne.co/gio-xach gio xach]. Indeed, this is a sensitive situation, but all in all, children shouldn't be discriminated against. And if a private group is going to discriminate against children, should they really be exempted from paying their fair share to the government? In a way, their lack of tax payment kind of makes it look like the government condones their behavior. | + | This section contains the first steps for getting started with SimplePie Live! Ready to get started? |
+ | ===== Requirements ===== | ||
+ | - A fundamental understanding of JavaScript is required, and an understanding of //JavaScript Object Notation// (aka [[http://json.org/js.html|JSON]]) is highly recommended. | ||
+ | - It would also be valuable to know how to generate HTML via JavaScript using DOM manipulation methods (so that you can dynamically add the feeds to your pages). | ||
+ | - Lastly, it would be valuable for you to have the latest version of [[http://getfirefox.com|Firefox]] installed along with the [[http://getfirebug.com|Firebug]] extension. Firebug is **the best** JavaScript debugging tool on the face of the entire planet... and it's easy to use. Even if you're a hard-core user of another browser, you should still install this combination of tools to that you can more easily dig through the data. | ||
+ | |||
+ | ===== Web Browsers ===== | ||
+ | Because SimplePie Live simply returns a JSON object of data, it is generally expected to work in ANY modern web browser. However, as we move forward, we will be following Yahoo's [[http://developer.yahoo.com/yui/articles/gbs/|Graded Browser Support]] in supporting A-grade web browsers. | ||
+ | |||
+ | Older versions of these browsers may also work as well, but we're pretty sure that these versions DO. In truth, you're more likely to be restricted by the minimum requirements of any JavaScript Framework than you are by SimplePie Live! | ||
+ | |||
+ | ===== Getting Started ===== | ||
+ | SimplePie Live doesn't require you to download any packages or configure any installs. It pulls straight from our servers and runs entirely within your web browser. That being said, there are two steps: | ||
+ | |||
+ | ==== Step 1: Load the base library ==== | ||
+ | First, you need to load the ''base.js'' file from the server by adding it to the ''<head>'' section of your page. | ||
+ | <code html><script type="text/javascript" src="http://live.simplepie.org/app/0.5/base.js"></script></code> | ||
+ | This file is less than 1k and includes the base functionality for requesting feeds and handling callbacks. Besides gzipping it (to make it super small), we've also resisted the temptation to add non-critical code to it, so this file should always remain very small (our goal is to always stay at or below 1k). | ||
+ | |||
+ | ==== Step 2: Call the function ==== | ||
+ | Secondly, you can request a feed and define callback functions for successful and failed requests. If you've ever worked with a modern JavaScript framework like [[http://prototypejs.org|Prototype]], [[http://jquery.com|jQuery]], or [[http://mootools.net|MooTools]] this will look pretty familiar. I should also note that you don't need to use one of these frameworks to use SimplePie Live -- you're free to use plain ol' JavaScript if you want. | ||
+ | <code html> | ||
+ | var feed = new SimplePie(feedUrl, jsonOptions); | ||
+ | </code> | ||
+ | Or, if you're looking for a more realistic example: | ||
+ | <code javascript> | ||
+ | var feed = new SimplePie('http://feeds.feedburner.com/simplepie', { | ||
+ | |||
+ | // Set one configuration option | ||
+ | setTimeout: 30, | ||
+ | |||
+ | // Set up a handler for a successful response | ||
+ | onSuccess: function(feed) { | ||
+ | alert(feed.title.toUpperCase() + "\n" + feed.description); | ||
+ | }, | ||
+ | |||
+ | // Do this if we encounter an error | ||
+ | onFailure: function(feed) { | ||
+ | alert(feed.error); | ||
+ | } | ||
+ | }); | ||
+ | </code> | ||
+ | |||
+ | That's basically the gist of it. If you need help on what configuration options are available, or what properties are available in the API, check out [[live:reference:start]]. |
live/setup/start.1367056692.txt.gz · Last modified: 2013/04/27 09:58 by tomrobert87