Commented Issue: Content within HTML conditional comments is ignored [6373]

0 views
Skip to first unread message

sparkviewengine Issue Tracker Rss Feed

unread,
Jul 28, 2010, 10:42:02 PM7/28/10
to spar...@googlegroups.com
What happens: When content is placed within an HTML conditional comment, it is not evaluated by Spark and instead output as a literal string.
What's expected: Content within an HTML conditional comment should be evaluated by Spark.

Example code to reproduce:
<!--[if IE 6]>
<link type="text/css" rel="stylesheet" media="screen" href="~/css/ie.6.css">
<![endif]-->

Expected Output:
<!--[if IE 6]>
<link type="text/css" rel="stylesheet" media="screen" href="http://mysiteroot.com/css/ie.6.css">
<![endif]-->

Actual Output:
<!--[if IE 6]>
<link type="text/css" rel="stylesheet" media="screen" href="~/css/ie.6.css">
<![endif]-->


I appreciate why this is happening - commented content should be ignored, but conditional comment should ideally be handled as a special case.


Further Information:
* Conditional Comments - http://en.wikipedia.org/wiki/Conditional_comment and http://www.quirksmode.org/css/condcom.html
Comments: ** Comment from web user: mattdotson **

You can work around this issue by putting the starting comment tag in a code block.

!{ "<!--[if IE 6]>" }

It would be nice if spark knew about this, but it's not that hard to work around.

URL: http://sparkviewengine.codeplex.com/workitem/6373

Reply all
Reply to author
Forward
0 new messages