DIV CSS 佈局教程網

 DIV+CSS佈局教程網 >> 網頁腳本 >> XML學習教程 >> XML詳解 >> IE7.0下浏覽動網論壇貼子顯示不全的問題解決方法
IE7.0下浏覽動網論壇貼子顯示不全的問題解決方法
編輯:XML詳解     

使論壇在IE7中正常浏覽的辦法。在風格模板page_dispbbs中找到以下代碼:

<!--判斷是否是IE,生成相應的style和class--><br />
<xsl:variable name="postclass"><br /><xsl:choose><br />
<xsl:when test="<a href="mailto:post/agent/@browser='Microsoft">post/agent/@browser='Microsoft</a> Internet Explorer'">postIE</xsl:when><br />
<xsl:otherwise>post</xsl:otherwise><br />
</xsl:choose><br /></xsl:variable><br />
<xsl:variable name="bodystyle"><br />
<xsl:choose><br />
<xsl:when test="<a href="mailto:post/agent/@browser='Microsoft">post/agent/@browser='Microsoft</a> Internet Explorer'">height:200px;width:97%;padding-right:0px; overflow-x: hidden;</xsl:when><br />
<xsl:otherwise>min-height:200px;</xsl:otherwise><br />
</xsl:choose>font-size:<xsl:value-of select="<a href="mailto:post/setting/@fontsize">post/setting/@fontsize</a>" />pt;line-height:<xsl:value-of select="<a href="mailto:post/setting/@lineheight">post/setting/@lineheight</a>" />;text-indent:<xsl:value-of select="<a href="mailto:post/setting/@indent">post/setting/@indent</a>" />px;
</xsl:variable><br />
<!--end -->

替換為:

<!--判斷是否是IE,生成相應的style和class-->
<xsl:variable name="postclass">
<xsl:choose>
<xsl:when test="post/agent/@browser='Microsoft Internet Explorer' and not(post/agent/@version > 6 ) ">postIE</xsl:when>
<xsl:otherwise>post</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:variable name="bodystyle">
<xsl:choose>
<xsl:when test="post/agent/@browser='Microsoft Internet Explorer' and not(post/agent/@version > 6 )">height:200px;width:97%;padding-right:0px; overflow-x: hidden;</xsl:when>
<xsl:otherwise>min-height:200px;</xsl:otherwise>
</xsl:choose>font-size:<xsl:value-of select="post/setting/@fontsize" />pt;line-height:<xsl:value-of select="post/setting/@lineheight" />;text-indent:<xsl:value-of select="post/setting/@indent" />px;</xsl:variable>
<!--end -->

XML學習教程| jQuery入門知識| AJAX入門| Dreamweaver教程| Fireworks入門知識| SEO技巧| SEO優化集錦|
Copyright © DIV+CSS佈局教程網 All Rights Reserved