hello_ggn
								2014-11-26 16:20:55
							
							
								等
							一个xml表达式,请各位帮帮忙
只有两个牛币了 全拿出来了。
想要的结果是:
<ul> <li></li>....10个 </ul> <ul> <li></li>....10个 </ul> <ul> <li></li>....10个 </ul>
目前输出的结果是:
<li></li> ....无限
呈现上源码,各位牛牛们帮帮。
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:ms="urn:schemas-microsoft-com:xslt"
                xmlns:lewi="" xmlns:pe="labelproc" exclude-result-prefixes="pe ms lewi">
    <xsl:output method="html" version="1.0" encoding="UTF-8" indent="yes"/>
    <xsl:param name="titleLength"/>
    <xsl:param name="linkOpenType"/>
    <xsl:template match="/">
        <xsl:choose>
            <xsl:when test="count(/NewDataSet/Table) = 0">
                <li style="color:red">还没有任何项目!</li>
            </xsl:when>
 
            <xsl:otherwise>
                <xsl:for-each select="/NewDataSet/Table">
                    <li>
                        <div class="pic">
                            <a>
                                <xsl:attribute name="href">
                                    <xsl:value-of select="SiteUrl"/>
                                </xsl:attribute>
                                <xsl:attribute name="target">
                                    <xsl:choose>
                                        <xsl:when test="pe:GetNodeFieldName(NodeID, 'ItemOpenType') = 0">_self</xsl:when>
                                        <xsl:otherwise>_blank</xsl:otherwise>
                                    </xsl:choose>
                                </xsl:attribute>
                                <xsl:element name="img">
                                    <xsl:attribute name="src">
                                        <xsl:choose>
                                            <xsl:when test="LogoUrl !=''">
                                                <xsl:if test="pe:IsStartWithhttp(LogoUrl)='false'">
                                                    <xsl:value-of select="pe:UpLoadDir()"/>
                                                </xsl:if>
                                                <xsl:value-of select="LogoUrl"/>
                                            </xsl:when>
                                            <xsl:otherwise><xsl:value-of select="pe:UpLoadDir()"/>nopic.gif
                                            </xsl:otherwise>
                                        </xsl:choose>
                                    </xsl:attribute>
                                    <xsl:attribute name="border">0</xsl:attribute>
                                    <xsl:attribute name="alt">
                                        <xsl:value-of select="pe:CutText(Title,$titleLength,'…')"/>
                                    </xsl:attribute>
                                </xsl:element>
                            </a>
                        </div>
                        <div class="title">
                            <a>
                                <xsl:attribute name="href">
                                    <xsl:value-of select="SiteUrl"/>
                                </xsl:attribute>
                                <xsl:attribute name="target">
                                    <xsl:choose>
                                        <xsl:when test="pe:GetNodeFieldName(NodeID, 'ItemOpenType') = 0">_self</xsl:when>
                                        <xsl:otherwise>_blank</xsl:otherwise>
                                    </xsl:choose>
                                </xsl:attribute>
                                <xsl:value-of select="pe:CutText(Title,$titleLength,'…')"/>
                            </a>
                        </div>
                    </li>
                </xsl:for-each>
            </xsl:otherwise>
        </xsl:choose>
    </xsl:template>
</xsl:stylesheet>
							
                评论
            
     所有回答列表(3)
所有回答列表(3)
				
            hexudonghot1     LV2
            2014年11月26日
        
        ello_ggn 2小时前
 <xsl:if test="(position() mod 10)=1">
                    <ul>
                   </xsl:if> 能算思路么
- 等 最代码怎么获取牛币啊?
- 完 谁来告诉我最代码上线的时间,答对者给5牛币,先来先得
- 等 牛友们,大家好,你们做程序员多久了?现在还好吗?
- 完 在微信打开的页面里进行app下载
- 等 最代码2014年欢乐聚声会
- 完 mysql如何查询表数据并且对3个字段降序的SQL?
- 完 最代码牛币机制改革
- 完 成功的在bae上使用了自定义运行环境 jetty+nginx的组合,大家对jetty+nginx优化有哪些心得?
- 完 进来分享一下各位牛牛是如何加入最代码大家庭的?
- 等 为什么java BufferedImage类处理大图直接抛出内存溢出的异常?
- 等 最代码是否开发手机app客户端?
- 完 java程序员学习哪些java的技术?java有哪些框架?都能做哪方面的开发?
- 等 php格式网页文件怎么运行?
- 等 Java volatile值获取的问题
- 等 前端vue,拦截了登录后台后,返回的token,requests拦截token,但是发送请求的时候,就出现跨越异常
- 等 大专本科计算机科班怎么找到Java工作?
- 等 eclipse怎么把三个java swing游戏项目合成一个项目?
- 完 伙伴们,大家都有什么好的解压方式么,分享一下~
- 完 三四线城市,6、7k,运维工作,索然无味,想去辞职上培训,各位牛牛有什么建议嘛
- 等 jsp页面输入中文变成问号
- 等 JPA在线上运行一段时间后报错Caused by: java.lang.IncompatibleClassChangeError: null
- 等 PHP 这个规则用preg_match_all怎么写
- 等 大佬们,有没有知道Alfresco如何配置LDAP登录呢?
- 等 php的install目录是框架带的吗?
 相关问答
相关问答
				- 等 xml解析为什么错误,错误提示: Character reference ?
- 等 今天学了XML知识,给点学习经验
- 完 怎么对xml文件的子节点下的多个属性做加密处理呢?
- 等 xml语言怎么学习啊?
- 完 xml文件中字符串带有冒号通过java怎么解析?
- 完 java读取Oracle11g clob存的xml文件,然后解析出来插入到另外一个表中
- 完 java dom4j解析xml字符串问题
- 等 门户网站XML实体注入漏洞(XXE)修改的问题
- 完 spring mvc接收微信发送xml数据始终不成功?
- 完 什么工具能最方便地由java类生成xml文件?
- 等 myeclipse配置 XML文件时自动提示内容缺少的问题
- 等 使用JDom组装XML为什么报错?
 最近浏览
最近浏览
				
                bhunkni     LV13
                2016年6月15日
            
            
        
                heel     LV24
                2014年12月15日
            
            
        
                最代码包妹     LV15
                2014年12月12日
            
            
        
                liujianniu     LV10
                2014年12月11日
            
            
        
                张家七少爷     LV3
                2014年12月8日
            
            
        
                202120401     LV2
                2014年12月2日
            
            
        
                vega315     LV5
                2014年12月2日
            
            
        
                Even     LV5
                2014年12月1日
            
            
        
                yzy_rl     LV8
                2014年12月1日
            
            
        
                xiaoyb1000     LV8
                2014年12月1日
            
            
        





 
                 
     
                