Simple_html_dom.php's use of simple_html_dom.php can be said to use PHP to process web pages, html can also be.
However, unlike java for processing different webpage codes, different codes are not processed and have been improved. The following describes how to use them:
(Note: Currently, only UTF8 or gb2312 web pages are read .)
In g/fw. php, the following definition is related to simple_html_dom:
$ MY_HTML_CONV = "utf8-> gb"; // This is the setting for reading UTF8 encoding.
$ IS_CURL = true; // use curl to read the webpage or use file_get_contents to read the webpage.
$ IS_CONV = true; // whether to use iconv () or mb_convert_encoding for transcoding <-- This is irrelevant to simple_html_dom
---------------------------------------------------------------------------------
Note: If you want to read the gb2312 encoding in a function, and you have specified in $ MY_HTML_CONV to read the UTF8 encoding, use the following:
Include ('simplehtmldom/simple_html_dom.php ');
// Read the content of the GB2312 webpage.
$ GLOBALS ['My _ HTML_CONV '] = null; // Note: This line is used to modify the value defined in g/fw. php.
$ Html = str_get_html ($ ct );
---------------------------------------------------------------------------------