The following two functions are used to obtain the source code of the website indexing query, which is used to query the baidu snapshot and indexing page.
The following two functions are used to obtain the source code of the website indexing query, which is used to query the baidu snapshot and indexing page.
Function baidu ()
{
Global $ murl, $ furl;
$ Url = "http://www.baidu.com/s? Wd = site: $ furl ";
$ Page = file_get_contents ($ url );
$ PageNum = "0 ";
$ PageNum = str_replace (",", "", cut ($ page, "Find related webpages", "article "));
If ($ PageNum = "") $ PageNum = str_replace (",", "", cut ($ page, "Find related webpage", "article "));
If ($ PageNum = "") $ PageNum = "0 ";
Echo "<a href = '". $ url. "'target =' _ blank '> $ PageNum </a> ";
}
Function baidukz ()
{
Global $ murl, $ furl;
$ Url = "http://www.baidu.com/s? Wd = $ furl ";
$ Page = file_get_contents ($ url );
$ Kzdate = "0 ";
$ Kzdate = cut ($ page, "<font color = #008000> $ furl", "</font> ");
If ($ kzdate! = ""){
// 37 K
$ Kzarray = explode ('k', $ kzdate );
$ Kzdate = trim ($ kzarray [1]);
If (trim ($ kzarray [1])! = ""){
Echo "<a href = '". $ url. "'target =' _ blank '> $ kzdate </a> ";
}
}
Else {
Echo escape ("NONE ");
}
}