I need to append Html element after an existing element in CsQuery, for example:
I've this code
CQ frgt = CQ.CreateFragment("<p>some text</p>");
CQ html = CQ.CreateFromFile("index.html");
// I also tried .Append instead of After
string x = html.Select("#test").After(frgt).Render();
index.html content:
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title></title>
</head>
<body>
<div id="page">
<div class="test">
<p>test</p>
</div>
</div>
</body>
</html>
The rendered string doesn't contain the 'frgt' content! What am I missing here?
Thanks