<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="html" />

<xsl:template name="IMGTextList">
 <xsl:param name="DataTable"/>

<ul>
    <xsl:for-each select="$DataTable">

         <li>
           <xsl:call-template name="ArticleImage"/>    
           <xsl:call-template name="ArticleText"/>
              
            </li>
 
 </xsl:for-each>

</ul>
</xsl:template>

<xsl:template name="TextList">
 <xsl:param name="DataTable"/>

<ul>
    <xsl:for-each select="$DataTable">

     <li><xsl:call-template name="ArticleText"/></li>
 
 </xsl:for-each>

</ul>
</xsl:template>

<xsl:template name="ArticleText">
          <xsl:choose>
                <xsl:when test="LinkType='0'">
                       <a> <xsl:attribute name="href">
{HL.Config.SiteUrl}/Shop/Article/Index.aspx?aid=<xsl:value-of select="ArticleID"/>
</xsl:attribute>
<xsl:value-of select="ShortTitle"/>
</a>                                          
                 </xsl:when>
                 <xsl:otherwise>
                       <a> <xsl:attribute name="href">
<xsl:value-of select="LinkUrl"/>
</xsl:attribute> <xsl:attribute name="target">_blank</xsl:attribute>
<xsl:value-of select="ShortTitle"/>
</a>
                  </xsl:otherwise>
          </xsl:choose>

</xsl:template>

<xsl:template name="ArticleImage">
<xsl:element name="img">
     <xsl:attribute name="src">{HL.Config.SiteUrl}/Shop/<xsl:value-of select="UploadPicUrl"/>
     </xsl:attribute>
</xsl:element>
</xsl:template>


</xsl:stylesheet>



 
