[Yanel-commits] rev 27090 - public/yanel/contributions/realms/foaf/src/resources/findfriend/xslt

michi at wyona.com michi at wyona.com
Sat Sep 1 00:53:52 CEST 2007


Author: michi
Date: 2007-09-01 00:53:52 +0200 (Sat, 01 Sep 2007)
New Revision: 27090

Modified:
   public/yanel/contributions/realms/foaf/src/resources/findfriend/xslt/foaf2xhtml.xsl
Log:
xhtml view added

Modified: public/yanel/contributions/realms/foaf/src/resources/findfriend/xslt/foaf2xhtml.xsl
===================================================================
--- public/yanel/contributions/realms/foaf/src/resources/findfriend/xslt/foaf2xhtml.xsl	2007-08-31 22:19:43 UTC (rev 27089)
+++ public/yanel/contributions/realms/foaf/src/resources/findfriend/xslt/foaf2xhtml.xsl	2007-08-31 22:53:52 UTC (rev 27090)
@@ -20,15 +20,66 @@
 <html xmlns="http://www.w3.org/1999/xhtml">
 <head>
   <title>Find a friend</title>
+  <link rel="foaf-introspection" type="application/foaf+xml" href="foaf-introspection.xml"/>
 </head>
 
 <body>
+<p>
+<a href="">Sign in</a> | <a href="">Sign up</a> | <a href="?q={$query}&amp;yanel.resource.viewid=source">XML view</a>
+</p>
+<xsl:choose>
+<xsl:when test="/foaf:foaf/foaf:provider">
+<p>
+<form action="advanced-search.html">
+<input type="text" name="q"><xsl:if test="$query != 'QUERY_IS_NULL'"><xsl:attribute name="value"><xsl:value-of select="$query"/></xsl:attribute></xsl:if></input>
+<input type="submit" value="Search"/>
+<br/>
+<a href="advanced-search.html?q={$query}">Advanced Search</a>
+</form>
+</p>
+<xsl:apply-templates select="/foaf:foaf/foaf:provider"/>
+<p>
+Copyright &#169; 2007 Wyona
+</p>
+</xsl:when>
+
+
+<xsl:otherwise>
+<center>
 <h1>Find a friend</h1>
+
 <p>
-<a href="?q={$query}&amp;yanel.resource.viewid=source">XML view</a>
+<form action="advanced-search.html">
+<input type="text" name="q"><xsl:if test="$query != 'QUERY_IS_NULL'"><xsl:attribute name="value"><xsl:value-of select="$query"/></xsl:attribute></xsl:if></input>
+<input type="submit" value="Search"/>
+<br/>
+<a href="advanced-search.html">Advanced Search</a>
+</form>
 </p>
+
+<p>
+Copyright &#169; 2007 Wyona
+</p>
+</center>
+</xsl:otherwise>
+</xsl:choose>
 </body>
 </html>
 </xsl:template>
 
+<xsl:template match="foaf:provider">
+  <hr/>
+  <xsl:apply-templates/>
+</xsl:template>
+
+<xsl:template match="foaf:result">
+  <p>
+  <b><a href="{foaf:url}"><xsl:value-of select="foaf:title"/></a></b>
+  <br/>
+  <xsl:value-of select="foaf:excerpt"/>
+  <br/>
+  <a href="sign-in.html">Add to your address book</a> | <a href="sign-in.html">Send invitation</a> | <a href="">Print</a>
+  </p>
+</xsl:template>
+
 </xsl:stylesheet>



More information about the Yanel-commits mailing list