{"id":51428,"date":"2020-03-14T18:06:54","date_gmt":"2020-03-14T10:06:54","guid":{"rendered":"http:\/\/4563.org\/?p=51428"},"modified":"2020-03-14T18:06:54","modified_gmt":"2020-03-14T10:06:54","slug":"%e6%b1%82%e5%8a%a9php-%e7%9a%84%e9%97%ae%e9%a2%98","status":"publish","type":"post","link":"http:\/\/4563.org\/?p=51428","title":{"rendered":"\u6c42\u52a9php \u7684\u95ee\u9898"},"content":{"rendered":"\n<p>  \t\t\t\t\t<strong>gnocuil<\/strong>  \t\t\t\t\u5927\u4f6c\u6709\u8bdd\u8bf4 : \t<\/p>\n<h3>\u6c42\u52a9php \u7684\u95ee\u9898<\/h3>\n<p>  \t\t\u6211\u7684\u76ee\u7684\u662f\u60f3\u7528\u4e0b\u9762\u8fd9\u6bb5php\u4ee3\u7801\u5b9e\u73b0\u8bbf\u95ee\u67d0\u4e2a\u7f16\u7801\u4e3autf-8\u7684\u7f51\u7ad9\uff0c\u6709\u6ca1\u529e\u6cd5\u628a\u8fd9\u4e2autf-8\u7684\u7f51\u7ad9\u8f6c\u6362\u4e3agbk\u7f16\u7801\u6b63\u5e38\u8f93\u51fa<\/p>\n<p>  &lt;?php<br \/>  $url =$_GET[&#8216;u&#8217;];<br \/>  echo $cont1 =get_url($url);<br \/>  function get_url($url,$host = null){<\/p>\n<p>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;$curl = curl_init();<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;curl_setopt($curl, CURLOPT_URL, $url);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;\/\/curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, 0);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;\/\/curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, 1);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;\/\/curl_setopt($curl, CURLOPT_USERAGENT, &quot;Mozilla\/4.0 (compatible; MSIE 8.0; Windows NT 6.1)&quot;);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;\/\/curl_setopt($curl, CURLOPT_FOLLOWLOCATION, $location);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;\/\/curl_setopt($curl, CURLOPT_FOLLOWLOCATION, 1);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;\/\/curl_setopt($curl, CURLOPT_AUTOREFERER, 1);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;\/\/curl_setopt($curl, CURLOPT_ENCODING, &quot;gzip&quot; );<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;\/\/curl_setopt($curl, CURLOPT_HTTPGET, 1);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;\/\/curl_setopt($curl, CURLOPT_COOKIE, $this-&gt;cookies);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;\/\/curl_setopt($curl, CURLOPT_COOKIEJAR, &#8216;cookie.txt&#8217;);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;\/\/curl_setopt($curl, CURLOPT_COOKIEFILE, &#8216;cookie.txt&#8217;);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;curl_setopt($curl, CURLOPT_TIMEOUT, 30);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;\/\/curl_setopt($curl, CURLOPT_HEADER, 1);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;\/\/curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;$tmpInfo = curl_exec($curl);<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;if (curl_errno($curl)) {<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp; echo&#8217;Curl error: &#8216;.curl_error ($curl);exit();<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;}<br \/>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;curl_close($curl);<\/p>\n<p>  &nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;&nbsp; &nbsp;return $tmpInfo;<br \/>   }<br \/>   ?&gt;\t\t\t\t<\/p>\n<p>  \t\t\t\t\t<strong>kydtf<\/strong>  \t\t\t\t\u5927\u4f6c\u6709\u8bdd\u8bf4 : \t<\/p>\n<h3><\/h3>\n<p>  \t\t\u697c\u4e0b\u89e3\u51b3:lol\t\t\t\t<\/p>\n<p>  \t\t\t\t\t<strong>inkedus<\/strong>  \t\t\t\t\u5927\u4f6c\u6709\u8bdd\u8bf4 : \t<\/p>\n<h3><\/h3>\n<p>  \t\t:lol<br \/>  &#8211;&lt; \u6211\u60f3\u6210\u4e3a\u4e00\u4e2a\u6e29\u67d4\u7684\u4eba,\u56e0\u4e3a\u66fe\u88ab\u6e29\u67d4\u7684\u4eba\u90a3\u6837\u5bf9\u5f85,\u6df1\u6df1\u4e86\u89e3\u90a3\u79cd\u88ab\u6e29\u67d4\u76f8\u5f85\u7684\u611f\u89c9\u3002\u2014\u2014\u300a\u590f\u76ee\u53cb\u4eba\u5e10\u300b &gt;&#8211;\t\t\t  <\/p>\n","protected":false},"excerpt":{"rendered":"<p>gnocuil \u5927\u4f6c\u6709\u8bdd\u8bf4 : \u6c42&hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[],"tags":[],"_links":{"self":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/51428"}],"collection":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=51428"}],"version-history":[{"count":0,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/51428\/revisions"}],"wp:attachment":[{"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=51428"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=51428"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=51428"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}