Pit*_*all 10 .net dom html-agility-pack
我只是想使用敏捷包创建我自己的简单文档,所以创建一个新的HtmlDocument只包含基本的容器元素 - 即
<html><head></head><body></body></html>
Run Code Online (Sandbox Code Playgroud)
如何在不实际加载htmldocument的情况下从头开始这样做.
Jef*_*ado 24
更简单:
var doc = new HtmlDocument();
var node = HtmlNode.CreateNode("<html><head></head><body></body></html>");
doc.DocumentNode.AppendChild(node);
Run Code Online (Sandbox Code Playgroud)