Ejemplo n.º 1
0
        /// <summary>
        /// Loads a HTML document from the given URL.
        /// </summary>
        /// <param name="url">The URL that hosts the HTML content.</param>
        /// <param name="configuration">[Optional] Custom options to use for the document generation.</param>
        /// <returns>The document with the parsed content.</returns>
        public static HTMLDocument LoadFromUrl(String url, IConfiguration configuration = null)
        {
            var doc = new HTMLDocument {
                Options = configuration ?? Configuration.Default
            };

            doc.Load(url);
            return(doc);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Loads a HTML document from the given URL.
        /// </summary>
        /// <param name="url">The URL that hosts the HTML content.</param>
        /// <returns>The document with the parsed content.</returns>
        public static HTMLDocument LoadFromURL(String url)
        {
            var doc = new HTMLDocument();

            return(doc.Load(url));
        }
Ejemplo n.º 3
0
 /// <summary>
 /// Loads a HTML document from the given URL.
 /// </summary>
 /// <param name="url">The URL that hosts the HTML content.</param>
 /// <returns>The document with the parsed content.</returns>
 public static HTMLDocument LoadFromURL(String url)
 {
     var doc = new HTMLDocument();
     return doc.Load(url);
 }