<s>
Conditional	B-Application
comments	I-Application
are	O
conditional	B-Language
statements	I-Language
interpreted	O
by	O
Microsoft	B-Application
Internet	I-Application
Explorer	I-Application
versions	O
5	B-Protocol
through	O
9	B-Application
in	O
HTML	B-Language
source	O
code	O
.	O
</s>
<s>
They	O
can	O
be	O
used	O
to	O
provide	O
and	O
hide	O
code	O
to	O
and	O
from	O
these	O
versions	O
of	O
Internet	B-Application
Explorer	I-Application
.	O
</s>
<s>
Conditional	B-Application
comments	I-Application
are	O
not	O
supported	O
in	O
Internet	B-Application
Explorer	I-Application
10	I-Application
and	O
11	B-Application
.	O
</s>
<s>
Conditional	B-Application
comments	I-Application
in	O
HTML	B-Language
first	O
appeared	O
in	O
Microsoft	O
's	O
Internet	B-Protocol
Explorer	I-Protocol
5	I-Protocol
browser	O
,	O
although	O
support	O
has	O
now	O
been	O
deprecated	O
.	O
</s>
<s>
In	O
Internet	B-Application
Explorer	I-Application
10	I-Application
,	O
HTML	B-Language
conditional	B-Application
comments	I-Application
are	O
not	O
supported	O
when	O
the	O
page	O
is	O
in	O
standards	O
mode	O
(	O
document	O
mode	O
10	O
)	O
.	O
</s>
<s>
JScript	B-Language
conditional	B-Application
comments	I-Application
were	O
introduced	O
in	O
Internet	B-Protocol
Explorer	I-Protocol
4	I-Protocol
,	O
and	O
they	O
continued	O
to	O
be	O
supported	O
in	O
Internet	B-Application
Explorer	I-Application
10	I-Application
,	O
in	O
standards	O
mode	O
or	O
compatibility	O
mode	O
.	O
</s>
<s>
Here	O
is	O
a	O
simple	O
example	O
that	O
demonstrates	O
how	O
conditional	B-Application
comments	I-Application
work	O
.	O
</s>
<s>
There	O
are	O
two	O
types	O
of	O
"	O
conditional	B-Application
comments	I-Application
"	O
:	O
downlevel	O
revealed	O
,	O
and	O
downlevel	O
hidden	O
.	O
</s>
<s>
The	O
first	O
comment	O
shown	O
is	O
the	O
basic	B-Language
HTML	I-Language
Comment	O
,	O
which	O
is	O
included	O
for	O
the	O
purpose	O
of	O
comparison	O
and	O
to	O
illustrate	O
the	O
different	O
syntax	O
used	O
by	O
each	O
type	O
of	O
conditional	B-Application
comment	I-Application
.	O
</s>
<s>
Comment	O
type	O
Syntax	O
or	O
possible	O
value	O
standard	O
HTML	B-Language
comment	O
<!-- Comment content  --> downlevel-hidden <!--[if expression]>	O
HTML	B-Language
<	O
!	O
</s>
<s>
[	O
if	O
expression ]	O
>	O
HTML	B-Language
<	O
!	O
</s>
<s>
The	O
HTML	B-Language
shown	O
inside	O
the	O
syntax	O
block	O
in	O
each	O
of	O
the	O
conditional	B-Application
comments	I-Application
denotes	O
any	O
block	O
of	O
HTML	B-Language
content	O
,	O
including	O
script	O
.	O
</s>
<s>
Both	O
types	O
of	O
conditional	B-Application
comment	I-Application
use	O
a	O
conditional	B-Language
expression	O
to	O
indicate	O
whether	O
the	O
content	O
inside	O
the	O
comment	O
block	O
should	O
be	O
parsed	O
or	O
ignored	O
.	O
</s>
<s>
The	O
conditional	B-Language
expression	O
is	O
formed	O
from	O
a	O
combination	O
of	O
feature	O
,	O
operator	O
,	O
and/or	O
value	O
,	O
depending	O
on	O
the	O
feature	O
.	O
</s>
<s>
Item	O
Example	O
Comment	O
IE	O
[	O
if	O
IE ]	O
The	O
string	O
"	O
IE	O
"	O
is	O
a	O
feature	O
corresponding	O
to	O
the	O
version	O
of	O
Internet	B-Application
Explorer	I-Application
used	O
to	O
view	O
the	O
Web	O
page	O
.	O
</s>
<s>
value	O
[	O
if	B-Application
IE	I-Application
7 ]	O
An	O
integer	O
or	O
floating	O
point	O
numeral	O
corresponding	O
to	O
the	O
version	O
of	O
the	O
browser	O
.	O
</s>
<s>
For	O
more	O
information	O
,	O
see	O
Version	B-Operating_System
vectors	I-Operating_System
.	O
</s>
<s>
WindowsEdition	O
[	O
if	O
WindowsEdition ]	O
Internet	B-Application
Explorer	I-Application
8	O
on	O
Windows	O
7	O
.	O
</s>
<s>
The	O
following	O
table	O
describes	O
the	O
operators	O
that	O
can	O
be	O
used	O
to	O
create	O
conditional	B-Language
expressions	O
.	O
</s>
<s>
lt	O
[	O
if	O
lt	O
IE	O
5.5	O
]	O
The	O
less-than	O
operator	O
.	O
</s>
<s>
&	O
[	O
if	O
(	O
gt	O
IE	B-Protocol
5	I-Protocol
)	O
&( 	O
lt	O
IE	O
7	O
)	O
]	O
The	O
AND	O
operator	O
.	O
</s>
<s>
Below	O
are	O
two	O
examples	O
of	O
a	O
"	O
downlevel	O
hidden	O
"	O
conditional	B-Application
comment	I-Application
:	O
</s>
<s>
Browsers	O
other	O
than	O
IE	O
will	O
also	O
ignore	O
it	O
because	O
it	O
looks	O
like	O
a	O
standard	O
HTML	B-Language
comment	O
.	O
</s>
<s>
The	O
tag	O
in	O
the	O
second	O
example	O
will	O
let	O
IE	O
versions	O
5.0	O
through	O
7	O
read	O
the	O
internal	O
CSS	O
style	O
.	O
</s>
<s>
With	O
different	O
uses	O
of	O
this	O
tag	O
you	O
can	O
also	O
single	O
out	O
IE	O
6	O
,	O
IE	B-Protocol
5	I-Protocol
,	O
or	O
versions	O
of	O
IE	O
that	O
are	O
newer	O
(	O
greater	O
)	O
or	O
older	O
(	O
less	O
)	O
than	O
a	O
specified	O
version	O
.	O
</s>
<s>
Below	O
is	O
an	O
example	O
of	O
a	O
"	O
downlevel	O
revealed	O
"	O
conditional	B-Language
'	O
comment	O
 '	O
,	O
which	O
is	O
not	O
an	O
(	O
X	O
)	O
HTML	B-Language
comment	O
at	O
all	O
,	O
despite	O
the	O
misleading	O
name	O
,	O
using	O
the	O
default	O
Microsoft	O
syntax	O
:	O
</s>
<s>
This	O
is	O
not	O
valid	O
HTML	B-Language
or	O
XHTML	O
.	O
</s>
<s>
In	O
order	O
to	O
ensure	O
compliance	O
with	O
W3C	O
standards	O
,	O
some	O
web	O
developers	O
use	O
an	O
alternative	O
technique	O
for	O
downlevel-revealed	O
conditional	B-Application
comments	I-Application
:	O
</s>
<s>
While	O
somewhat	O
confusing	O
in	O
structure	O
,	O
this	O
specific	O
syntax	O
is	O
valid	O
(	O
X	O
)	O
HTML	B-Language
and	O
is	O
useful	O
for	O
conditional	B-Language
sections	O
intended	O
specifically	O
for	O
non-IE	O
browsers	O
;	O
if	O
the	O
condition	O
evaluates	O
to	O
true	O
(	O
for	O
example	O
,	O
if	O
writing	O
code	O
meant	O
to	O
display	O
on	O
non-IE	O
browsers	O
and	O
on	O
some	O
versions	O
of	O
IE	O
)	O
,	O
IE	O
will	O
then	O
display	O
the	O
"	O
-->	O
 "	O
present	O
before	O
the	O
HTML	B-Language
content	O
.	O
</s>
<s>
is	O
ignored	O
by	O
non-IE	O
browsers	O
;	O
it	O
is	O
also	O
ignored	O
by	O
IE	O
regardless	O
of	O
the	O
condition	O
because	O
if	O
false	O
,	O
everything	O
within	O
the	O
conditional	B-Application
comment	I-Application
is	O
ignored	O
,	O
and	O
if	O
true	O
,	O
the	O
resulting	O
tag	O
<!-->	O
is	O
unrecognized	O
and	O
therefore	O
ignored	O
.	O
</s>
<s>
Starting	O
with	O
Internet	B-Protocol
Explorer	I-Protocol
4	I-Protocol
,	O
there	O
exists	O
a	O
similar	O
proprietary	O
mechanism	O
for	O
adding	O
conditional	B-Application
comments	I-Application
within	O
JScript	B-Language
,	O
known	O
as	O
conditional	B-Language
compilation	O
.	O
</s>
<s>
There	O
were	O
also	O
several	O
predefined	O
variables	O
,	O
though	O
these	O
cannot	O
be	O
relied	O
on	O
any	O
longer	O
as	O
Microsoft	O
altered	O
the	O
JScript	B-Language
engine	O
of	O
IE6	O
with	O
XP	O
SP3	O
and	O
it	O
now	O
reports	O
as	O
:	O
</s>
<s>
As	O
a	O
result	O
,	O
a	O
possible	O
way	O
to	O
detect	O
Internet	B-Application
Explorer	I-Application
version	O
using	O
conditional	B-Language
compilation	O
can	O
be	O
seen	O
below	O
:	O
</s>
<s>
However	O
,	O
conditional	B-Language
compilation	O
is	O
no	O
longer	O
supported	O
in	O
Internet	B-Application
Explorer	I-Application
11	I-Application
Standards	O
mode	O
.	O
</s>
