xsl-list
[Top] [All Lists]

Re: IE's conditional comments in xslt

2006-03-04 15:01:18
This came out completely off the mark: > The code I originally posted will hide the code from IE7, but show it to all down-level browsers, including Fx, etc... (its just seen as a comment.) That looks (obviously :) like:.

Obviously (I hope! :) this should have suggested that the code will be hidden from IE7. but IE6 will see it just fine, as will IE 5.5 and 5.0 (I believe, need to check the docs to be certain which conditional syntax would allow these browsers to see it as well). But in any other browse it will simply be seen as a comment.

Setting this portion aside, I am now intrigued to hear about what it is you are attempting, and how you are proposing to solve this. I think I originally assumed too much as to what it seemed to be you were trying to solve.

M. David Peterson wrote:

Manfred Staudinger wrote:

On 04/03/06, M. David Peterson <xmlhacker(_at_)gmail(_dot_)com> wrote:
You haven't fully got it yet:

I guess not. What is that you are trying to output? Or, better said, what browser are you trying to hide from? The original code you showed had a bunch of escaped entities so I didnt tear into to deeply. I seem to remember you stating something to the effect if not doing browser sniffing. Client or Server? and why? I'm sure your reason is valid, just curious as to why the concern. The code I originally posted will hide the code from IE7, but show it to all down-level browsers, including Fx, etc... (its just seen as a comment.) That looks (obviously :) like:.

   <!--[if lt IE 7]>
   <script src="foo.js" type="text/javascript"></script>
   <![endif]-->


None of the other browsers see the IE specific conditional in the first place,

This is true only for downlevel-hidden CC's, but you have to see that
the only thing I hide from other browsers is that one downlevel-revealed CC.
For example, the content between these two lines
<xsl:comment><![CDATA[[if IE]><![if IE 7]><![endif]]]></xsl:comment>
and
<xsl:comment><![CDATA[[if IE]><![endif]><![endif]]]></xsl:comment>
is perfectly visible for all non-IE browsers plus IE 7!
Okay. Still not sure as to what it is you are trying to hide and what you are trying to show. Maybe this will help me understand the purpose for all of this?

If you are going to go the
system-property route then visit http://www.jenitennison.com/ , click
the index.xml link in the upper left hand corner, and view the source
to locate the URI to the stylesheet, you can then access this
styelsheet and see how she has elequently used the extended system
property info made available as part of the MSXML processor to
determined browser version.

No, she determines the version of MSXML, not the browser version.
Ahh... okay... Its been a while since I've looked at her code... need to go back and check it out again and refresh my memory what she is looking for. Possibly for MSXML2? I'll look again. Thanks for the correction!

Its an interesting site implementation, thanks for the link anyway.
Sure.

Manfred

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--





--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--





--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--



<Prev in Thread] Current Thread [Next in Thread>