调查问卷标签样式修改
一般我们默认的问卷调查标签是这种形式:
因为临澧县政府项目设计图的原因,改造了这个标签。
我们首先复制一下默认的问卷调查标签:
我们要在sql语句上添加时间和描述的字段 :Description , CreateDate
- SELECT TOP @pagesize SurveyName,SurveyID,CreateDate,Description,FileName,IsOpen FROM PE_Survey WHERE SurveyID NOT IN(
- SELECT TOP @startrow SurveyID from PE_Survey WHERE IsOpen = 1 ORDER BY CreateDate DESC
- ) AND IsOpen = 1 ORDER BY CreateDate DESC
接着是添加时间这个参数
- <attributes>
- <name>displayDateTimename>
- <datatype>stringdatatype>
- <default>
- default>
- <intro>是否显示日期,为空则不显示intro>
- attributes>
最后把下面的架构全部打掉,重新编辑:
- <xsl:choose>
- <xsl:when test="count(/NewDataSet/Table) = 0">
- <li class="noData">暂无资料li>
- xsl:when>
- <xsl:otherwise>
- <xsl:for-each select="/NewDataSet/Table">
- <xsl:choose>
- <xsl:when test="$topicNum > 0 and position() <= $topicNum">
- <li class="t">
- <div class="con">
- <div class="title">
- <a class="ques">
- <xsl:attribute name="href">{PE.SiteConfig.ApplicationPath/}Survey/<xsl:value-of select="FileName"/>xsl:attribute>
- <xsl:attribute name="target">_blankxsl:attribute>
- <xsl:attribute name="title">
- <xsl:value-of select="SurveyName"/>
- xsl:attribute>
- <xsl:value-of select="pe:CutText(SurveyName,$titleLength,'...')"/>
- a>
- div>
- <xsl:if test="$contentLength > 0">
- <div class="intro">
- <xsl:if test="Description != ''"><xsl:value-of disable-output-escaping="yes" select="pe:CutText(pe:RemoveHtml(Description),$contentLength,'…')" />
- xsl:if>
- div>
- xsl:if>
- div>
- <a class="join">
- <xsl:attribute name="href">
- {PE.SiteConfig.ApplicationPath/}Survey/<xsl:value-of select="FileName"/>
- xsl:attribute>
- <xsl:attribute name="target">_blankxsl:attribute>参与调查a>
- <a class="view">
- <xsl:attribute name="href">
- {PE.SiteConfig.ApplicationPath/}Survey/ListReport.aspx?SurveyID=<xsl:value-of select="SurveyID"/>
- xsl:attribute>查看结果a>
- li>
- xsl:when>
- <xsl:otherwise>
- <li class="n">
- <xsl:if test="$displayDateTime != ''"><span class="date"><xsl:value-of select="pe:FormatDate(CreateDate, $displayDateTime)"/>span>xsl:if>
- <a class="ques">
- <xsl:attribute name="href">{PE.SiteConfig.ApplicationPath/}Survey/<xsl:value-of select="FileName"/>
- xsl:attribute>
- <xsl:attribute name="target">_blank
- xsl:attribute>
- <xsl:attribute name="title">
- <xsl:value-of select="SurveyName"/>
- xsl:attribute>
- <xsl:value-of select="pe:CutText(SurveyName,$titleLength,'...')"/>
- a>
- li>
- xsl:otherwise>
- xsl:choose>
就这样完成一个头条信息问卷调查,通过这个标签,也延伸一个内容信息问卷调查标签:
附带2个标签
头条信息问卷调查
内容信息问卷调查
用户登录
还没有账号?
立即注册