incubator-xap-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mtu...@apache.org
Subject svn commit: r469051 - in /incubator/xap/trunk/WebContent/examples/dataBinding: playlistfeed.xml rss_example.html rss_example.xal
Date Mon, 30 Oct 2006 03:08:02 GMT
Author: mturyn
Date: Sun Oct 29 19:08:01 2006
New Revision: 469051

URL: http://svn.apache.org/viewvc?view=rev&rev=469051
Log:
An example using an RSS feed, with a local version of the source for Mozilla use until we've
got a good way of hitting foreign hosts.

Added:
    incubator/xap/trunk/WebContent/examples/dataBinding/playlistfeed.xml
    incubator/xap/trunk/WebContent/examples/dataBinding/rss_example.html
    incubator/xap/trunk/WebContent/examples/dataBinding/rss_example.xal

Added: incubator/xap/trunk/WebContent/examples/dataBinding/playlistfeed.xml
URL: http://svn.apache.org/viewvc/incubator/xap/trunk/WebContent/examples/dataBinding/playlistfeed.xml?view=auto&rev=469051
==============================================================================
--- incubator/xap/trunk/WebContent/examples/dataBinding/playlistfeed.xml (added)
+++ incubator/xap/trunk/WebContent/examples/dataBinding/playlistfeed.xml Sun Oct 29 19:08:01
2006
@@ -0,0 +1,215 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--most_recent_playlists_rss main template Written 9/8/06, (C) 2006 by Ken Garson. v9/13/06-->
+<rss version="2.0">
+	<channel>
+		<title>WFMU's recent playlists</title>
+		<link>http://wfmu.org</link>
+		<description>WFMU's most recent playlists, updated every time a DJ publishes a new
playlist! http://wfmu.org</description>
+		<language>en</language>
+		<copyright>Copyright (C) 2006 WFMU</copyright>
+		<pubDate>Sun, 29 Oct 2006 16:26:08 EST</pubDate>
+		<lastBuildDate>Sun, 29 Oct 2006 16:26:08 EST</lastBuildDate>
+
+
+		<item>
+			<title>WFMU Playlist: Give the Drummer Some with Doug Schulkind from Oct 27, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20859</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20859"&gt;Playlist&lt;/a&gt;
from Give the Drummer Some with Doug Schulkind on WFMU, from Oct 27, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20859</guid>
+			<pubDate>Sun, 29 Oct 2006 14:13:37 EST</pubDate>
+
+		</item>
+
+		<item>
+			<title>WFMU Playlist: Dan Mackta's show from Nov 2, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20886</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20886"&gt;Playlist&lt;/a&gt;
from Dan Mackta's show on WFMU, from Nov 2, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20886</guid>
+			<pubDate>Sun, 29 Oct 2006 16:26:08 EST</pubDate>
+		</item>
+		<item>
+
+			<title>WFMU Playlist: The Evan &quot;Funk&quot; Davies Show from Oct 29,
2006</title>
+			<link>http://wfmu.org/playlists/shows/20884</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20884"&gt;Playlist&lt;/a&gt;
from The Evan &quot;Funk&quot; Davies Show on WFMU, from Oct 29, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20884</guid>
+
+			<pubDate>Sun, 29 Oct 2006 14:56:18 EST</pubDate>
+		</item>
+		<item>
+			<title>WFMU Playlist: Tony Coulter's show from Oct 28, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20879</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20879"&gt;Playlist&lt;/a&gt;
from Tony Coulter's show on WFMU, from Oct 28, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20879</guid>
+			<pubDate>Sun, 29 Oct 2006 13:15:04 EST</pubDate>
+		</item>
+
+		<item>
+			<title>WFMU Playlist: Evan Muse from Oct 29, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20881</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20881"&gt;Playlist&lt;/a&gt;
from Evan Muse on WFMU, from Oct 29, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20881</guid>
+			<pubDate>Sun, 29 Oct 2006 11:49:24 EST</pubDate>
+		</item>
+		<item>
+
+			<title>WFMU Playlist: Airborn Event with Dan Bodah from Oct 29, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20882</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20882"&gt;Playlist&lt;/a&gt;
from Airborn Event with Dan Bodah on WFMU, from Oct 29, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20882</guid>
+			<pubDate>Sun, 29 Oct 2006 08:58:48 EST</pubDate>
+		</item>
+		<item>
+			<title>WFMU Playlist: The Cherry Blossom Clinic with Terre T from Oct 28, 2006</title>
+
+			<link>http://wfmu.org/playlists/shows/20875</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20875"&gt;Playlist&lt;/a&gt;
from The Cherry Blossom Clinic with Terre T on WFMU, from Oct 28, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20875</guid>
+			<pubDate>Sat, 28 Oct 2006 18:00:39 EDT</pubDate>
+		</item>
+		<item>
+			<title>WFMU Playlist: Michael Shelley's show from Oct 28, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20871</link>
+
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20871"&gt;Playlist&lt;/a&gt;
from Michael Shelley's show on WFMU, from Oct 28, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20871</guid>
+			<pubDate>Sat, 28 Oct 2006 12:58:52 EDT</pubDate>
+		</item>
+		<item>
+			<title>WFMU Playlist: Bryce's show from Oct 27, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20870</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20870"&gt;Playlist&lt;/a&gt;
from Bryce's show on WFMU, from Oct 27, 2006</description>
+
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20870</guid>
+			<pubDate>Sat, 28 Oct 2006 02:38:33 EDT</pubDate>
+		</item>
+		<item>
+			<title>WFMU Playlist: Jason Elbogen's show from Oct 27, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20860</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20860"&gt;Playlist&lt;/a&gt;
from Jason Elbogen's show on WFMU, from Oct 27, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20860</guid>
+
+			<pubDate>Fri, 27 Oct 2006 23:50:56 EDT</pubDate>
+		</item>
+		<item>
+			<title>WFMU Playlist: Pseu Braun's show from Oct 27, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20868</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20868"&gt;Playlist&lt;/a&gt;
from Pseu Braun's show on WFMU, from Oct 27, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20868</guid>
+			<pubDate>Fri, 27 Oct 2006 23:00:50 EDT</pubDate>
+
+		</item>
+		<item>
+			<title>WFMU Playlist: Downtown Soulville with Mr. Fine Wine from Oct 27, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20869</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20869"&gt;Playlist&lt;/a&gt;
from Downtown Soulville with Mr. Fine Wine on WFMU, from Oct 27, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20869</guid>
+			<pubDate>Fri, 27 Oct 2006 20:11:23 EDT</pubDate>
+		</item>
+
+		<item>
+			<title>WFMU Playlist: Scott Williams's show from Oct 27, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20862</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20862"&gt;Playlist&lt;/a&gt;
from Scott Williams's show on WFMU, from Oct 27, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20862</guid>
+			<pubDate>Fri, 27 Oct 2006 14:59:52 EDT</pubDate>
+		</item>
+		<item>
+
+			<title>WFMU Playlist: Bill Zurat's show from Oct 27, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20858</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20858"&gt;Playlist&lt;/a&gt;
from Bill Zurat's show on WFMU, from Oct 27, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20858</guid>
+			<pubDate>Fri, 27 Oct 2006 08:58:25 EDT</pubDate>
+		</item>
+		<item>
+			<title>WFMU Playlist: Pat Duncan's show from Oct 26, 2006</title>
+
+			<link>http://wfmu.org/playlists/shows/20853</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20853"&gt;Playlist&lt;/a&gt;
from Pat Duncan's show on WFMU, from Oct 26, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20853</guid>
+			<pubDate>Fri, 27 Oct 2006 03:49:36 EDT</pubDate>
+		</item>
+		<item>
+			<title>WFMU Playlist: Debbie's show from Oct 26, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20857</link>
+
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20857"&gt;Playlist&lt;/a&gt;
from Debbie's show on WFMU, from Oct 26, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20857</guid>
+			<pubDate>Fri, 27 Oct 2006 00:32:18 EDT</pubDate>
+		</item>
+		<item>
+			<title>WFMU Playlist: Diane's Kamikaze Fun Machine from Oct 26, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20851</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20851"&gt;Playlist&lt;/a&gt;
from Diane's Kamikaze Fun Machine on WFMU, from Oct 26, 2006</description>
+
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20851</guid>
+			<pubDate>Thu, 26 Oct 2006 17:59:53 EDT</pubDate>
+		</item>
+		<item>
+			<title>WFMU Playlist: Strength through Failure with Fabio from Oct 26, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20850</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20850"&gt;Playlist&lt;/a&gt;
from Strength through Failure with Fabio on WFMU, from Oct 26, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20850</guid>
+
+			<pubDate>Thu, 26 Oct 2006 15:01:47 EDT</pubDate>
+		</item>
+		<item>
+			<title>WFMU Playlist: This Is the Modern World with Trouble from Oct 26, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20848</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20848"&gt;Playlist&lt;/a&gt;
from This Is the Modern World with Trouble on WFMU, from Oct 26, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20848</guid>
+			<pubDate>Thu, 26 Oct 2006 11:59:56 EDT</pubDate>
+
+		</item>
+		<item>
+			<title>WFMU Playlist: Trent's show from Oct 26, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20847</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20847"&gt;Playlist&lt;/a&gt;
from Trent's show on WFMU, from Oct 26, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20847</guid>
+			<pubDate>Thu, 26 Oct 2006 09:01:18 EDT</pubDate>
+		</item>
+
+		<item>
+			<title>WFMU Playlist: Tony Rettman's show from Oct 26, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20846</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20846"&gt;Playlist&lt;/a&gt;
from Tony Rettman's show on WFMU, from Oct 26, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20846</guid>
+			<pubDate>Thu, 26 Oct 2006 05:58:53 EDT</pubDate>
+		</item>
+		<item>
+
+			<title>WFMU Playlist: Coffee Break For Heroes &amp; Villains with Noah from
Oct 25, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20845</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20845"&gt;Playlist&lt;/a&gt;
from Coffee Break For Heroes &amp; Villains with Noah on WFMU, from Oct 25, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20845</guid>
+			<pubDate>Thu, 26 Oct 2006 02:00:51 EDT</pubDate>
+
+		</item>
+		<item>
+			<title>WFMU Playlist: World of Echo with Dave Mandl from Oct 25, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20844</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20844"&gt;Playlist&lt;/a&gt;
from World of Echo with Dave Mandl on WFMU, from Oct 25, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20844</guid>
+			<pubDate>Wed, 25 Oct 2006 22:54:50 EDT</pubDate>
+		</item>
+
+		<item>
+			<title>WFMU Playlist: Maria Levitsky's show from Oct 25, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20841</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20841"&gt;Playlist&lt;/a&gt;
from Maria Levitsky's show on WFMU, from Oct 25, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20841</guid>
+			<pubDate>Wed, 25 Oct 2006 21:06:07 EDT</pubDate>
+		</item>
+		<item>
+
+			<title>WFMU Playlist: Phuj Phactory with Ergo Phizmiz from Oct 25, 2006</title>
+			<link>http://wfmu.org/playlists/shows/20842</link>
+			<description>&lt;a href="http://wfmu.org/playlists/shows/20842"&gt;Playlist&lt;/a&gt;
from Phuj Phactory with Ergo Phizmiz on WFMU, from Oct 25, 2006</description>
+			<guid isPermaLink="true">http://wfmu.org/playlists/shows/20842</guid>
+			<pubDate>Wed, 25 Oct 2006 20:22:23 EDT</pubDate>
+		</item>
+	</channel>
+</rss>
+
+<!--Generated dynamically by <strong>KenzoDB</strong>, designed and programmed
by <a href="http://counterfolk.com/ken/extrav/">Ken Garson</a>-->

Added: incubator/xap/trunk/WebContent/examples/dataBinding/rss_example.html
URL: http://svn.apache.org/viewvc/incubator/xap/trunk/WebContent/examples/dataBinding/rss_example.html?view=auto&rev=469051
==============================================================================
--- incubator/xap/trunk/WebContent/examples/dataBinding/rss_example.html (added)
+++ incubator/xap/trunk/WebContent/examples/dataBinding/rss_example.html Sun Oct 29 19:08:01
2006
@@ -0,0 +1,72 @@
+<html>
+	<head>
+		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
+		<title>RSS feed: WFMU programming</title>
+
+		<style type="text/css">
+      <!--
+          @import url(../../css/xapDefault.css);
+      -->
+    </style>
+
+		<!-- Keep dojo from trying to scan this whole page for dojoType'd tags: -->
+		<script type="text/javascript">
+		djConfig = {
+			parseWidgets: false
+		};
+	</script>
+
+		<script language="JavaScript" type="text/javascript" src="../../xapcore.js"></script>
+		<!--  No longer need this---now grabs JS source using source object's 'path' attribute:
-->
+		<!--  script language="JavaScript" type="text/javascript" src="Employees.js"></script
-->
+
+<!--  
+Remove debugging in a final check, since debugging's 
+alternate loading method (using <script/> tags) can
+mask forgetting a .require(<className>) in the code:
+-->
+
+    <script language="JavaScript" type="text/javascript">
+
+    	Xap._sourceRootDir = "../../" ; 	
+		Xap.addDebuggables(		
+							"xap.data.DataFramework",
+							"xap.data.DataServiceFactory",
+							"xap.data.DataServiceImpl",
+							"xap.data.bridge.DataAttributeConverter",
+							"xap.data.bridge.DataFrameworkBridge",
+							"xap.data.bridge.DataSourceBridge",
+							"xap.data.bridge.IteratorBridge",							
+							"xap.data.bridge.SimpleDocumentDataSourceBridge",							
+							"xap.data.bridge.ObjectDataSourceBridge",
+							"xap.data.controller.ContextFrame",		
+							"xap.data.controller.Iterator",
+							"xap.data.controller.Binding",							
+							"xap.data.datasource.AbstractDataSet",
+							"xap.data.datasource.AbstractDataSource",							
+							"xap.data.datasource.ArrayDataSet",
+							"xap.data.datasource.DataSetFactory",						
+							"xap.data.datasource.DataSourceContainerImpl",
+							"xap.data.datasource.DataSourceImpl",
+							"xap.data.datasource.SimpleDocumentDataSource",
+							"xap.resolver.AttributeResolutionHandler",
+							"xap.session.ClientSession",
+							"xap.session.DeclarativeArgumentParser",
+							"xap.taghandling.AbstractTagImpl",							
+							"xap.taghandling.AttributeConverter",
+							"xap.util.Vector",
+							"xap.xml.dom.Document",
+							"xap.xml.dom.XapElement",							
+							"xap.Xap"																							
+							) ;
+		Xap._loadDebuggables() ;
+							
+	</script>							
+
+	</head>
+
+	<body onload="Xap.createAllPredefinedSessions();">
+		<div id="titleDisplay"></div>
+		<div style="left:100px;top:100px" xapId="RssExample" xapSrc="rss_example.xal" xapToolkit="dojo"
xapContext="../../"></div>
+	</body>
+</html>

Added: incubator/xap/trunk/WebContent/examples/dataBinding/rss_example.xal
URL: http://svn.apache.org/viewvc/incubator/xap/trunk/WebContent/examples/dataBinding/rss_example.xal?view=auto&rev=469051
==============================================================================
--- incubator/xap/trunk/WebContent/examples/dataBinding/rss_example.xal (added)
+++ incubator/xap/trunk/WebContent/examples/dataBinding/rss_example.xal Sun Oct 29 19:08:01
2006
@@ -0,0 +1,83 @@
+<xal 
+	xmlns="http://www.openxal.org/xal" 
+	xmlns:xal="http://www.openxal.org/xal" 
+	xmlns:data="http://www.openxal.org/data" 
+	xmlns:xm="http://www.openxal.org/xmodify"
+>
+
+
+	<data:simpleDocumentDataSource 
+		id="rssFeed" 
+		source="http://wfmu.org/playlistfeed.xml" 
+		local-source="playlistfeed.xml" 		
+	/>
+
+	<data:binding 	
+		dataSource="rssFeed" 
+		select="concat('# Items: ',count(/rss/channel/item))" 
+		id="itemCount"
+	/>
+
+	
+	<borderLayout/>
+	
+	
+
+	<table borderPosition="center"   height="250px" width="500px">
+
+		<column>
+			<header text="Show: [links to playlist]" />
+		</column>
+		<column/>
+		<column>
+			<header text="Date:" />
+		</column>
+
+		<data:iterator 
+			name="item-iterator" 
+			dataSource="rssFeed" 
+			select="/rss/channel/item"
+		>
+
+			<!-- 
+				The following shows what to do when you've already 
+				used " and ' in expressions---use &quot; as follows: 
+			-->
+			<row>		
+				<cell text="{ bind(&quot;dataSource=item-iterator;select=concat(substring-before(description,'>'),'>',substring-after(substring-before(title,'from'),':
'),'</a>')&quot;) }" />
+				<!-- cell text="{ *('guid') }" / -->	
+				<cell text=". . . . " color="#FFffFF"/>	
+				<cell text="{ bind(&quot;dataSource=item-iterator;select=substring-after(title,'from')&quot;)
}" />
+				<!-- cell text="{ *('pubDate') }" / -->	
+			</row>		
+		</data:iterator>
+	</table>
+
+	<label 
+		text="{ bind(binding:itemCount) }" 
+		borderPosition="south" 
+		height="30" 
+	/>
+
+
+
+
+
+
+
+
+	<xm:modifications document="html">
+		<!-- Doesn't work for IE--yet. -->
+		<xm:append select="/HTML/HEAD">
+			<script language="JavaScript">document.title = "RSS test: WFMU programming"</script>
+		</xm:append>
+		<!-- Fine in both target browsers: -->
+		<xm:append select="//*[@id='titleDisplay']">
+			<h3>RSS feed: WFMU programming.</h3>
+		</xm:append>
+	</xm:modifications>
+
+
+
+</xal>
+<!-- -->



Mime
View raw message