This article mainly introduces the PHP implementation of the collection of Chinese proxy server network, interested in the reference of friends, I hope to be helpful to everyone.
This paper introduces the method of PHP to collect Chinese proxy server network. Specific as follows:
Summary: The above is the entire cont
How php collects the Chinese proxy server network
This example describes how php collects the proxy server network in China. Share it with you for your reference. The details are as follows:
I hope this article will help you with php programming.
650) this.width=650; "src=" Http://s3.51cto.com/wyfs02/M01/82/A4/wKioL1deFW-zAADKAADjEFpGZTA173.png "title=" capture. PNG "width=" 556 "height=" 218 "border=" 0 "hspace=" 0 "vspace=" 0 "style=" width:556px;height:218px; "alt=" Wkiol1defw-zaadkaadjefpgzta173.png "/>Just met a walk agent to visit the customer set up in the intranet 17.x.x.x site users, the DMZ request to go our agent, think about, probably network architecture diagram650) this.width=650
2. Install SquidThe Yum command is ready to be installed directly online Yum Install Squid After the installation is complete, Cd/etc/squid/, modify the contents of the squid.conf file before you modify it, you can back up the file first: CP squid.conf Squid.conf_bak Then find http_access deny all in the file and modify it to http_access allow all to indicate that all users have access to the agent. Also found Http_port 3128 modified to http_port 192.168.3.171:3128 here IP and port is squid
When using a Java net package to access the network, if you need to use a proxy, you can do this:
System. getproperties (). setproperty ("proxyset", "true"); system. getproperties (). setproperty ("HTTP. proxyhost "," 183.121.23.188 "); system. getproperties (). setproperty ("HTTP. proxyport "," 8080 "); Url url = new URL (http://www.163.com); httpurlconnection httpconn = (httpurlconnection) URL. openconne
In an environment where an external network must be accessed through an agent, a program that is written in Java for external access will not connect properly, by setting the proxy implementation access in code.The proxy settings are set through several system parameters:System.getproperties (). Put ("Proxyset", "true");System.getproperties (). Put ("ProxyHost",
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.