예제 #1
0
        public List <HtmlChunk> ParseToChunks(string html)
        {
            //List<HtmlChunk> controls = new List<HtmlChunk>();
            //Read header tag, if any.
            HtmlDoc htmDoc = new HtmlDoc(html);

            //Get the plugin for this doctype
            IHtmlParserPlugin parser = _plugins[htmDoc.DocumentType];

            //Get Chunks
            return(parser.CreateChunks(htmDoc));
        }
예제 #2
0
        public System.Web.UI.Control[] ParseToControls(System.Web.UI.Page page, string html)
        {
            List <System.Web.UI.Control> controls = new List <System.Web.UI.Control>();
            //Read header tag, if any.
            HtmlDoc htmDoc = new HtmlDoc(html);

            //Get the plugin for this doctype
            IHtmlParserPlugin parser = _plugins[htmDoc.DocumentType];

            //Get Chunks
            return(parser.CreateControls(page, htmDoc));
        }