Is it possible to differentiate between IE8 and IE9 using XSL/XPATH?
I'm trying to determine browser version using XSL only. I'm able to determine browser type with:
<xsl:if test="system-property('xsl:vendor') = 'Microsoft'">
This test will give me the MSXSL version, but both IE8 and IE9 seem to use version 3.
<xsl:value-of xmlns:msxsl="urn:schemas-microsoft-com:xslt" select="system-prope开发者_开发问答rty('msxsl:version')" />
Is there anything else I can do?
Thanks in advance!
AFAIK, IE9 uses/will use MSXML6.
You can use this by retrieving this information with:
system-property('msxsl:version')
where the prefix msxsl:
is bound to the namespace "urn:schemas-microsoft-com:xslt"
.
For IE x, where x <= 8 the result is <= 3.
For IE9 the result is 6
.
精彩评论