[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> lite
From: |
Phil Sainty |
Subject: |
bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> literally instead of dropping the tags |
Date: |
Tue, 12 Jul 2022 05:46:54 +1200 |
User-agent: |
Orcon Webmail |
On 2022-07-12 01:04, Lars Ingebrigtsen wrote:
I'm starting to wonder... is
<![if !bar]>Foo<![endif]>
valid syntax? It's apparently an MSIE-ism:
https://en.wikipedia.org/wiki/Conditional_comment
Yes, I believe that's invalid, and therefore it's expected
behaviour that it would have a visible effect upon rendering.
So unless HTML5 has legitimised it, it's not really a bug.
I recall encountering this unique-to-MSIE syntax well over
a decade ago at an old job, and establishing a safe way to
get the same outcome without using it, because it wasn't
valid to use.
It's unfortunate that this still exists in the wild. Now
that MSIE is officially dead, and assuming it's *not* part
of HTML5, it would be nice if things generating that syntax
were updated to not do that. (Perhaps libxml has dropped
support for it as a result of MSIE reaching end-of-life?)
I think what I came up with at the time was probably the
same thing I can see at that wikipedia link, which is that
instead of writing this:
<![if CONDITION]>
<link href="non-ie.css" rel="stylesheet">
<![endif]>
You instead structure it within valid comments like this:
<!--[if CONDITION]><!-->
<link href="non-ie.css" rel="stylesheet">
<!--<![endif]-->
Difficult to fix at the source if arbitrary people are
sending you this as email, though :(
-Phil
- bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> literally instead of dropping the tags, Justus-dev, 2022/07/10
- bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> literally instead of dropping the tags, Lars Ingebrigtsen, 2022/07/11
- bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> literally instead of dropping the tags, Visuwesh, 2022/07/11
- bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> literally instead of dropping the tags, Lars Ingebrigtsen, 2022/07/11
- bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> literally instead of dropping the tags, Visuwesh, 2022/07/11
- bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> literally instead of dropping the tags, Lars Ingebrigtsen, 2022/07/11
- bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> literally instead of dropping the tags, Justus-dev, 2022/07/11
- bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> literally instead of dropping the tags, Lars Ingebrigtsen, 2022/07/11
- bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> literally instead of dropping the tags, Visuwesh, 2022/07/11
- bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> literally instead of dropping the tags, Lars Ingebrigtsen, 2022/07/11
- bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> literally instead of dropping the tags,
Phil Sainty <=
- bug#56482: 29.0.50; shr displays <![if !supportLists]>...<![endif]> literally instead of dropping the tags, Lars Ingebrigtsen, 2022/07/12