Php code for obtaining website ICP filing information (360)

Source: Internet
Author: User

Copy codeThe Code is as follows:
<? Php
// WebSite http://www.micxp.com
Function miibeian ($ domain ){
$ Domain = base64_encode ($ domain );
$ Opts = array (
'Http' => array (
'Method' => "GET ",
'Timeout' => 5
)
);
$ Context = stream_context_create ($ opts );
$ Url = 'HTTP: // webid.360.cn/complaininfo.php? Domain = '. $ domain;
$ Html = file_get_contents ($ url, false, $ context );
If (strpos ($ html, 'no website information found ')){
Return false;
}
$ Flag = '<ul> ';
$ Start = strpos ($ html, $ flag) + strlen ($ flag );
$ Info = substr ($ html, $ start, strpos ($ html, '</ul>')-$ start );

$ Info = str_replace ('','', $ info );
$ Info = str_replace ('<li> <strong> website name: </strong>', ', $ info );
$ Info = str_replace ('<li> <strong> Homepage Address: </strong>', ', $ info );
$ Info = str_replace ('<li> <strong> organizer name: </strong>', '', $ info );
$ Info = str_replace ('<li> <strong> subject nature: </strong>', '', $ info );
$ Info = str_replace ('<li> <strong> audit time: </strong>', '', $ info );
$ Info = str_replace ('<li> <strong> website record filing/license No.: </strong>', ', $ info );
$ Info = str_replace ("\ r \ n", '', $ info );
$ Info = str_replace ('</li>', '', $ info );
$ Info = trim ($ info );
$ Temp = explode ('', $ info );
Return $ temp;
}
// Http://webid.360.cn/complaininfo.php? Domain = c3lzeXVuLmNvbQ =
$ Result = miibeian ('jb51. net ');
Print_r ($ result );

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.