Not sure what happened to the original post from jgurley, so here's a continuation....
The rdf namespace definition includes several other namespaces, among them the rss namespace. When you refer to an element that you want to use, you need to use the namespaces prefix to find it, which is why we use the rss:description designation. I know that's brief, but more info is available on other xml/xsl sites.
Now, one tactic I use to help with layouts, is to just create a simple HTML page with the layout I envision, using just simple text in place of the xml elements I intend to use. Once I get the layout setup, I can take care of the xml/xsl pieces. One thing about xsl is that it is very unforgiving of HTML mistakes. Any HTML you use must be well-formed, otherwise the xml/xsl parser will choke and spit seemingly incorrect error messages.
It is a pain to translate RDF, so any HTML you use better be well-formed. Now, I should have told you that I actually, corrected some HTML to get the feed to display after changing the literals to actual HTML tags. That's probably why you are still having issues. So, being a bit nerdish, I'm giving you an example that may help get you a bit further along. Breaking on date is very problematic as xsl scripting is limited due to issues with security, but there are ways to do it using the xml/xsl module, but it involves code changes, which are a bit more involved.
Here's a sample xsl I am using with that feed. It may not be exactly what you need, but it should give you a bit more bits and tricks to examine. Anyway, check it out...
Cheers,
iwonder ;-)
<?xml version='1.0'?>
<xsl:stylesheet
version="1.0" exclude-result-prefixes="rdf rss l dc admin content xsl"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:rss="http://purl.org/rss/1.0/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:admin="http://webns.net/mvcb/"
xmlns:l="http://purl.org/rss/1.0/modules/link/"
xmlns:content="http://purl.org/rss/1.0/modules/content/">
<!-- phil 'iwonder' guerra - xsl simple rdf translation file. -->
<xsl:output omit-xml-declaration="yes"/>
<xsl:param name="currentDate"/>
<xsl:variable name="Today" select="$currentDate"/>
<xsl:template match="/rdf:RDF">
<html><head></head><body>
<table ><tbody width="100%">
<th align="left">Date</th>
<th align="left">Time</th>
<th align="left">Tide</th>
<th align="left">Height</th>
<th align="left">Event</th>
<xsl:for-each select="rss:item">
<xsl:variable name="title" select="rss:title"/>
<xsl:variable name="desc" select="rss:description"/>
<xsl:variable name="date" select="substring-before($desc,' at')"/>
<xsl:variable name="mydate" select="dc:date"/>
<xsl:if test="contains($title,'High Tide')">
<tr>
<td><xsl:value-of select="$date" disable-output-escaping="yes"/></td>
<td><xsl:value-of select="substring-before(substring-after($desc,'at '),': ')" disable-output-escaping="yes"/></td>
<td><xsl:value-of select="substring(substring-after($desc,'feet '),1,4)" disable-output-escaping="yes"/></td>
<td><xsl:value-of select="substring-before(substring-after($desc,'T: '),'feet')" disable-output-escaping="yes"/> feet </td>
<td>High Tide</td>
</tr>
</xsl:if>
<xsl:if test="contains($title,'Low Tide')">
<tr>
<td><xsl:value-of select="$date" disable-output-escaping="yes"/></td>
<td><xsl:value-of select="substring-before(substring-after($desc,'at '),': ')" disable-output-escaping="yes"/></td>
<td><xsl:value-of select="substring(substring-after($desc,'feet '),1,4)" disable-output-escaping="yes"/></td>
<td><xsl:value-of select="substring-before(substring-after($desc,'T: '),'feet')" disable-output-escaping="yes"/> feet </td>
<td>Low Tide</td>
</tr>
</xsl:if>
<xsl:if test="(contains($desc,'Sunrise'))">
<tr>
<td><xsl:value-of select="$date" disable-output-escaping="yes"/></td>
<td><xsl:value-of select="substring-before(substring-after($desc,'at '),': ')" disable-output-escaping="yes"/></td>
<td> ----- </td>
<td> ----- </td>
<td>Sunrise</td>
</tr>
</xsl:if>
<xsl:if test="(contains($desc,'Moonset'))">
<tr>
<td><xsl:value-of select="$date" disable-output-escaping="yes"/></td>
<td><xsl:value-of select="substring-before(substring-after($desc,'at '),': ')" disable-output-escaping="yes"/></td>
<td> ----- </td>
<td> ----- </td>
<td>Moonset</td>
</tr>
</xsl:if>
<xsl:if test="(contains($desc,'Moonrise'))">
<tr>
<td><xsl:value-of select="$date" disable-output-escaping="yes"/></td>
<td><xsl:value-of select="substring-before(substring-after($desc,'at '),': ')" disable-output-escaping="yes"/></td>
<td> ----- </td>
<td> ----- </td>
<td>Moonrise</td>
</tr>
</xsl:if>
<xsl:if test="(contains($desc,'Sunset'))">
<tr>
<td><xsl:value-of select="$date" disable-output-escaping="yes"/></td>
<td><xsl:value-of select="substring-before(substring-after($desc,'at '),': ')" disable-output-escaping="yes"/></td>
<td> ----- </td>
<td> ----- </td>
<td>Sunset</td>
</tr>
</xsl:if>
</xsl:for-each>
</tbody></table></body></html>
</xsl:template>
</xsl:stylesheet>
It gives me output something like this:
Date |
Time |
Tide |
Height |
Event |
2008-06-25 |
5:42 AM PDT |
----- |
----- |
Sunrise |
2008-06-25 |
10:52 AM PDT |
Low |
0.62 feet |
Low Tide |
2008-06-25 |
12:44 PM PDT |
----- |
----- |
Moonset |
2008-06-25 |
5:40 PM PDT |
Hig |
6.19 feet |
High Tide |
2008-06-25 |
8:56 PM PDT |
----- |
----- |
Sunset |
2008-06-26 |
12:03 AM PDT |
Low |
2.04 feet |
Low Tide |
2008-06-26 |
12:47 AM PDT |
----- |
----- |
Moonrise |
2008-06-26 |
5:31 AM PDT |
Hig |
4.68 feet |
High Tide |
2008-06-26 |
5:43 AM PDT |
----- |
----- |
Sunrise |
2008-06-26 |
11:34 AM PDT |
Low |
1.24 feet |
Low Tide |
2008-06-26 |
1:54 PM PDT |
----- |
----- |
Moonset |
2008-06-26 |
6:19 PM PDT |
Hig |
6.52 feet |
High Tide |
2008-06-26 |
8:56 PM PDT |
----- |
----- |
Sunset |
2008-06-27 |
1:10 AM PDT |
----- |
----- |
Moonrise |
2008-06-27 |
1:11 AM PDT |
Low |
1.32 feet |
Low Tide |
2008-06-27 |
5:43 AM PDT |
----- |
----- |
Sunrise |
2008-06-27 |
6:57 AM PDT |
Hig |
4.37 feet |
High Tide |
2008-06-27 |
12:24 PM PDT |
Low |
1.87 feet |
Low Tide |
2008-06-27 |
3:07 PM PDT |
----- |
----- |
Moonset |
2008-06-27 |
7:03 PM PDT |
Hig |
6.88 feet |
High Tide |
2008-06-27 |
8:56 PM PDT |
----- |
----- |
Sunset |
2008-06-28 |
1:37 AM PDT |
----- |
----- |
Moonrise |
2008-06-28 |
2:16 AM PDT |
Low |
0.48 feet |
Low Tide |
2008-06-28 |
5:43 AM PDT |
----- |
----- |
Sunrise |
2008-06-28 |
8:26 AM PDT |
Hig |
4.35 feet |
High Tide |
2008-06-28 |
1:20 PM PDT |
Low |
2.43 feet |
Low Tide |
2008-06-28 |
4:24 PM PDT |
----- |
----- |
Moonset |
2008-06-28 |
7:51 PM PDT |
Hig |
7.25 feet |
High Tide |
2008-06-28 |
8:56 PM PDT |
----- |
----- |
Sunset |
2008-06-29 |
2:10 AM PDT |
----- |
----- |
Moonrise |
2008-06-29 |
3:16 AM PDT |
Low |
-0.38 feet |
Low Tide |
2008-06-29 |
5:44 AM PDT |
----- |
----- |
Sunrise |
2008-06-29 |
9:47 AM PDT |
Hig |
4.58 feet |
High Tide |
2008-06-29 |
2:24 PM PDT |
Low |
2.84 feet |
Low Tide |
2008-06-29 |
5:44 PM PDT |
----- |
----- |
Moonset |