﻿<xsl:stylesheet version="1.0" 
	xmlns:date="http://exslt.org/dates-and-times"
	xmlns:xsl="http://www.w3.org/1999/XSL/Transform" exclude-result-prefixes="date">

<xsl:output omit-xml-declaration="yes" />

<xsl:param name="IsBlogOwner" />
<xsl:param name="RelativeUrl" />

<xsl:template match="/">

	<div class="blogCommentContainer" style="">
		<div class="commentContainer">
			<a name="postComments"> </a>
			<h3>Comments</h3>
			<!--<xsl:apply-templates select="rows/row"/>-->
		</div>
	</div>
</xsl:template>

<xsl:template match="row">
	
	<div class="commentContainer">
		<span class="commentDate">
			<xsl:variable name="publishedDate" select="date:parseDate(Created, 'yyyy-MM-dd HH:mm:ss')"/>
			<xsl:value-of select="date:format-date($publishedDate, 'EEEE, d MMM yyyy hh:mm')"/>
			by
      <xsl:choose>
        <xsl:when test="CommentUrl != ''">
          <a>
            <xsl:attribute name="href">
              <xsl:if test="starts-with(CommentUrl, 'http') = false">
                http://
              </xsl:if>
              <xsl:value-of select="CommentUrl" />
            </xsl:attribute>
            <xsl:value-of select="Title"/>
          </a>
        </xsl:when>
        <xsl:otherwise>
          <xsl:value-of select="Title"/>
        </xsl:otherwise>
      </xsl:choose>
	  </span>
	
		<blockquote>
			<xsl:value-of select="Body" disable-output-escaping="yes" />
		</blockquote>
	
		<hr class="commentSep" />
	</div>

</xsl:template>
  
</xsl:stylesheet>
