<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>app/helpers/examples.py</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -45,7 +45,9 @@ To run locally:
 
 - public/css/yui: [YUI](http://developer.yahoo.com/yui/) grid, fonts, reset (CSS)
 - public/images/...: [famfamfam](http://www.famfamfam.com/lab/icons/silk/) Silk icons
+
 - public/swf/player.swf: [JW Flash audio player](http://www.jeroenwijering.com/?item=JW_FLV_Media_Player)
+- public/swf/xspf_player*.swf: [XSPF Music Player](http://musicplayer.sourceforge.net/)
 
 Main leaf icon was purchased from iStockPhoto and is licensed by me (Gabriel Handford).
 </diff>
      <filename>README.md</filename>
    </modified>
    <modified>
      <diff>@@ -1,5 +1,6 @@
 # -*- coding: utf-8 -*-
 &lt;%namespace name=&quot;base&quot; module=&quot;app.helpers.base&quot;/&gt;\
+&lt;%namespace name=&quot;examples&quot; module=&quot;app.helpers.examples&quot;/&gt;\
 &lt;%inherit file=&quot;layout.mako&quot; /&gt;
 
 &lt;div id=&quot;doc&quot; class=&quot;index&quot;&gt;    
@@ -38,24 +39,28 @@
           
           &lt;hr/&gt;
           
-          &lt;h2&gt;Questions?&lt;/h2&gt;
+          &lt;h2 id=&quot;questions&quot;&gt;Questions?&lt;/h2&gt;
           &lt;p&gt;Visit the google group: &lt;a href=&quot;http://groups.google.com/group/shrub-gae&quot;&gt;shrub-gae&lt;/a&gt;&lt;/p&gt;
           
           &lt;hr/&gt;
           
-          &lt;h2&gt;Source&lt;/h2&gt;
+          &lt;h2 id=&quot;source&quot;&gt;Source&lt;/h2&gt;
           &lt;p&gt;Shrub is open source. You can find it at github: &lt;a href=&quot;http://github.com/gabriel/shrub/tree/master&quot;&gt;gabriel/shrub&lt;/a&gt;&lt;/p&gt;
           
           &lt;hr/&gt;
           
-          &lt;h2&gt;URL parameters&lt;/h2&gt;
+          &lt;h2 id=&quot;url_params&quot;&gt;URL parameters&lt;/h2&gt;
           
           &lt;p&gt;These parameters are available to all requests.&lt;/p&gt;
           &lt;table id=&quot;url-params&quot; class=&quot;tabular&quot;&gt;
             &lt;thead&gt;
               &lt;tr&gt;&lt;th&gt;Parameter&lt;/th&gt; &lt;th&gt;Description&lt;/th&gt; &lt;th&gt;Accepted&lt;/th&gt; &lt;th&gt;Default&lt;/th&gt;&lt;/tr&gt;
             &lt;tbody&gt;
-            &lt;tr&gt;&lt;td&gt;format&lt;/td&gt; &lt;td&gt;Response format&lt;/td&gt; &lt;td&gt;rss,json,id3-json,tape&lt;/td&gt; &lt;td&gt;None (HTML)&lt;/td&gt;&lt;/tr&gt;
+            &lt;tr&gt;
+              &lt;td&gt;format&lt;/td&gt; &lt;td&gt;Response format&lt;/td&gt; 
+              &lt;td&gt;&lt;a href=&quot;#rss&quot;&gt;rss&lt;/a&gt;&lt;br/&gt;&lt;a href=&quot;#json&quot;&gt;json&lt;/a&gt;&lt;br/&gt;&lt;a href=&quot;#id3&quot;&gt;id3-json&lt;/a&gt;&lt;br/&gt;&lt;a href=&quot;#xspf&quot;&gt;xspf&lt;/a&gt;&lt;br/&gt;&lt;a href=&quot;#tape&quot;&gt;tape&lt;/a&gt;&lt;/td&gt; 
+              &lt;td&gt;None (HTML)&lt;/td&gt;
+            &lt;/tr&gt;
             &lt;tr&gt;&lt;td&gt;delimiter&lt;/td&gt; &lt;td&gt;See S3 docs&lt;/td&gt; &lt;td&gt;Passed to S3&lt;/td&gt; &lt;td&gt; / &lt;/td&gt;&lt;/tr&gt;
             &lt;tr&gt;&lt;td&gt;prefix&lt;/td&gt; &lt;td&gt;See S3 docs&lt;/td&gt; &lt;td&gt;Passed to S3&lt;/td&gt; &lt;td&gt; &lt;/td&gt;&lt;/tr&gt;
             &lt;tr&gt;&lt;td&gt;marker&lt;/td&gt; &lt;td&gt;See S3 docs&lt;/td&gt; &lt;td&gt;Passed to S3&lt;/td&gt; &lt;td&gt; &lt;/td&gt;&lt;/tr&gt;
@@ -66,12 +71,13 @@
           
           &lt;hr/&gt;          
           
-          &lt;h2&gt;RSS&lt;/h2&gt;
-          &lt;p&gt;Get RSS feed with &lt;em&gt;format=rss&lt;/em&gt; URL parameter. &lt;br/&gt; For example, &lt;a href=&quot;/s3hub?format=rss&quot;&gt;http://shrub.appspot.com/s3hub?format=rss&lt;/a&gt; &lt;br/&gt;&lt;span class=&quot;disclaimer&quot;&gt;See limitations below.&lt;/span&gt;&lt;/p&gt;
+          &lt;h2 id=&quot;rss&quot;&gt;RSS&lt;/h2&gt;
+          &lt;p&gt;Generate an RSS 2.0 feed with &lt;em&gt;format=rss&lt;/em&gt; URL parameter. &lt;br/&gt; For example, &lt;a href=&quot;/s3hub?format=rss&quot;&gt;http://shrub.appspot.com/s3hub?format=rss&lt;/a&gt;.&lt;br/&gt;
+          &lt;span class=&quot;disclaimer&quot;&gt;See limitations below.&lt;/span&gt;&lt;/p&gt;
           
           &lt;hr/&gt;
           
-          &lt;h2&gt;JSON&lt;/h2&gt;
+          &lt;h2 id=&quot;json&quot;&gt;JSON&lt;/h2&gt;
           &lt;p&gt;Get list bucket response in JSON format with &lt;em&gt;format=json&lt;/em&gt; URL parameter.&lt;br/&gt; For example, &lt;a href=&quot;/s3hub?format=json&quot;&gt;http://shrub.appspot.com/s3hub?format=json&lt;/a&gt; &lt;br/&gt;&lt;span class=&quot;disclaimer&quot;&gt;See limitations below.&lt;/span&gt;&lt;br/&gt;&lt;br/&gt;&lt;/p&gt;
 &lt;pre&gt;
 {&quot;maxKeys&quot;: &quot;1000&quot;, 
@@ -104,10 +110,16 @@
             &lt;tr&gt;&lt;td&gt;callback&lt;/td&gt; &lt;td&gt;Callback function name to use in response&lt;/td&gt; &lt;td&gt;Callback function names may only use upper and lowercase alphabetic characters (A-Z, a-z), numbers (0-9), the period (.), the underscore (_)&lt;/td&gt; &lt;td&gt; &lt;/td&gt;&lt;/tr&gt;
             &lt;/tbody&gt;
           &lt;/table&gt;
-          
+          &lt;br/&gt;
+          &lt;br/&gt;
+          &lt;p&gt;Example of &lt;a href=&quot;http://shrub.appspot.com/s3hub?format=json&quot;&gt;http://shrub.appspot.com/s3hub?format=json&amp;callback=myCallback&lt;/a&gt;:&lt;/p&gt;
+          &lt;br/&gt;
+&lt;pre&gt;
+myCallback({&quot;maxKeys&quot;: &quot;1000&quot;, &quot;prefix&quot;: &quot;&quot;, ...})
+&lt;/pre&gt;
           &lt;hr/&gt;
           
-          &lt;h2&gt;ID3&lt;/h2&gt;
+          &lt;h2 id=&quot;id3&quot;&gt;ID3&lt;/h2&gt;
           &lt;p&gt;Lookup ID3 information (returned as JSON) for an MP3 with &lt;em&gt;format=id3-json&lt;/em&gt; URL parameter. &lt;br/&gt;For example, &lt;a href=&quot;/m1xes/sub-pop-mix-1/01-Dntel-The_Distance_(ft._Arthur%26Yu).mp3?format=id3-json&quot;&gt;
             http://shrub.appspot.com/m1xes/sub-pop-mix-1/01-Dntel-The_Distance_(ft._Arthur%26Yu).mp3?format=id3-json&lt;/a&gt;
             &lt;br/&gt;&lt;br/&gt;
@@ -131,6 +143,47 @@
           &lt;p&gt;This request accepts JSON url parameters (like callback). See JSON section for more info.&lt;/p&gt;
             
           &lt;hr/&gt;
+          &lt;h2 id=&quot;xspf&quot;&gt;XSPF&lt;/h2&gt;
+          &lt;p&gt;Generate an XSPF playlist of media files in a bucket or folder with &lt;em&gt;format=xspf&lt;/em&gt; URL parameter.&lt;br/&gt;
+          For example, &lt;a href=&quot;/m1xes/sub-pop-mix-1/?format=xspf&quot;&gt;http://shrub.appspot.com/m1xes/sub-pop-mix-1/?format=xspf&lt;/a&gt;
+          &lt;/p&gt;
+          &lt;br/&gt;
+          &lt;br/&gt;
+          
+&lt;pre style=&quot;overflow:auto; width=380px&quot;&gt;
+${examples.xspf_xml() | h}
+&lt;/pre&gt;
+          &lt;hr/&gt;
+          &lt;h3 id=&quot;music-player&quot;&gt;Embeddable music player&lt;/h3&gt;
+          &lt;p&gt;Embed an &lt;a href=&quot;http://musicplayer.sourceforge.net/&quot;&gt;xspf music player&lt;/a&gt;, pointing to an XSPF format. For example:&lt;br/&gt;
+          &lt;a href=&quot;http://shrub.appspot.com/m1xes/sub-pop-mix-1/?format=xspf&quot;&gt;http://shrub.appspot.com/m1xes/sub-pop-mix-1/?format=xspf&lt;/a&gt;
+          &lt;/p&gt;
+          &lt;br/&gt;
+          &lt;br/&gt;
+          
+          &lt;h4&gt;XSPF Slim Player&lt;/h4&gt;
+          &lt;div id=&quot;xspf-slim-player&quot; class=&quot;flash-player warn&quot;&gt;&lt;span&gt;You need Javascript enabled and/or a recent version of Flash for the XSPF Slim Player to work.&lt;/span&gt;&lt;/div&gt;
+          &lt;hr/&gt;
+          
+          &lt;h4&gt;XSPF Player&lt;/h4&gt;
+          &lt;div id=&quot;xspf-player&quot; class=&quot;flash-player warn&quot;&gt;&lt;span&gt;You need Javascript enabled and/or a recent version of Flash for the XSPF player to work.&lt;/span&gt;&lt;/div&gt;
+          &lt;hr/&gt;
+          &lt;h4&gt;Object embed example&lt;/h4&gt;
+&lt;pre style=&quot;overflow:auto; width=380px&quot;&gt;
+${examples.xspf_slim_player(&quot;http://shrub.appspot.com/m1xes/sub-pop-mix-1/?format=xspf&quot;) | h}
+&lt;/pre&gt;
+          &lt;hr/&gt;
+          &lt;h4&gt;SWFObject embed example&lt;/h4&gt;
+&lt;pre style=&quot;overflow:auto; width=380px&quot;&gt;
+${examples.xspf_slim_player_swf_object(&quot;http://shrub.appspot.com/m1xes/sub-pop-mix-1/?format=xspf&quot;) | h}
+&lt;/pre&gt;
+          
+          &lt;hr/&gt;
+          
+          &lt;h2&gt;Crossdomain&lt;/h2&gt;
+          &lt;p&gt;There is a &lt;a href=&quot;/crossdomain.xml&quot;&gt;crossdomain.xml&lt;/a&gt;, so you can use URLs from flash. For example, an &lt;a href=&quot;#music-player&quot;&gt;XSPF Music Player&lt;/a&gt;.&lt;/p&gt;
+          
+          &lt;hr/&gt;
           
           &lt;h2&gt;*Tape&lt;/h2&gt;
           &lt;p&gt;Present bucket or directory as a tape (like MuxTape/OpenTape, etc) with &lt;em&gt;format=tape&lt;/em&gt; URL parameter. &lt;br/&gt;For example, &lt;a href=&quot;/m1xes/sub-pop-mix-1/?format=tape&quot;&gt;http://shrub.appspot.com/m1xes/sub-pop-mix-1/?format=tape&lt;/a&gt; &lt;br/&gt;Currently only supports mp3's. Track information is displayed using ID3v2 info (see above).&lt;/p&gt;
@@ -162,4 +215,28 @@
     &lt;p class=&quot;disclaimer&quot;&gt;Amazon is a registered trademark of Amazon.com, Inc. or its subsidiaries in the U.S. and/or other countries.&lt;/p&gt;
   &lt;/div&gt;
         
-&lt;/div&gt;
\ No newline at end of file
+&lt;/div&gt;
+
+&lt;script type=&quot;text/javascript&quot;&gt;
+var loadXspfPlayer = function() {
+  var xspfUrl = &quot;http://shrub.appspot.com/m1xes/sub-pop-mix-1/?format=xspf&quot;;
+  var flashvars = { };
+	var params = { allowscriptaccess: &quot;always&quot; };
+	var attributes = { id: &quot;xspf-player&quot;, name: &quot;xspf-player&quot;, styleclass:&quot;xspf-player&quot; };
+	
+	swfobject.embedSWF('/shrub/swf/xspf_player.swf?playlist_url=' + encodeURI(xspfUrl), &quot;xspf-player&quot;, &quot;400&quot;, &quot;170&quot;, &quot;8.0.0&quot;, false, flashvars, params, attributes);
+};
+
+var loadXspfSlimPlayer = function() {
+  var xspfUrl = &quot;http://shrub.appspot.com/m1xes/sub-pop-mix-1/?format=xspf&quot;;
+  var flashvars = { };
+	var params = { allowscriptaccess: &quot;always&quot; };
+	var attributes = { id: &quot;xspf-slim-player&quot;, name: &quot;xspf-slim-player&quot;, styleclass:&quot;xspf-slim-player&quot; };
+	
+	swfobject.embedSWF('/shrub/swf/xspf_player_slim.swf?playlist_url=' + encodeURI(xspfUrl), &quot;xspf-slim-player&quot;, &quot;400&quot;, &quot;15&quot;, &quot;8.0.0&quot;, false, flashvars, params, attributes);
+};
+
+$(document).ready(loadXspfSlimPlayer);
+$(document).ready(loadXspfPlayer);
+
+&lt;/script&gt;</diff>
      <filename>app/views/index.mako</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>c651a3b3e6883f7b766b9a5c96f07a8ad34be711</id>
    </parent>
  </parents>
  <author>
    <name>Gabriel Handford</name>
    <email>gabrielh@gmail.com</email>
  </author>
  <url>http://github.com/gabriel/shrub/commit/50cda84c45ff65933de1520b63f605d4f28d7eca</url>
  <id>50cda84c45ff65933de1520b63f605d4f28d7eca</id>
  <committed-date>2009-02-21T15:57:42-08:00</committed-date>
  <authored-date>2009-02-21T15:57:42-08:00</authored-date>
  <message>Updating documentation</message>
  <tree>e6a18699b591ee7f3a1c7b82b4f72096ed61b899</tree>
  <committer>
    <name>Gabriel Handford</name>
    <email>gabrielh@gmail.com</email>
  </committer>
</commit>
