How to supplement the page capture of other sites across sites and capture site pages

Source: Internet
Author: User

How to supplement the page capture of other sites across sites and capture site pages

In practical applications, we often encounter special situations, such as the need for news, weather forecasts, and so on, however, as personal websites or websites with low strength, we cannot do this with so much human, material, and financial resources. What should we do?
Fortunately, resources are shared on the Internet. We can use programs to automatically capture the pages of other sites and use them for processing.
What is the use? What the comrade-in-arms gave is not feasible. In fact, this function is provided in Php, that is, the curl library is used. Please refer to the following code!
<? Php

$ Ch = curl_init ("http://dailynews.sina.com.cn ");
$ Fp = fopen ("php_homepage.txt", "w ");

Curl_setopt ($ ch, CURLOPT_FILE, $ fp );
Curl_setopt ($ ch, CURLOPT_HEADER, 0 );

Curl_exec ($ ch );
Curl_close ($ ch );
Fclose ($ fp );
?>

Http://php.662p.com/thread-504-1-1.html


How can I solve cross-site problems?

<Body onUnload = "opener. location. reload ()">
Change
<Body onUnload = "opener. reload ()">
You can.

How does one Set Directory security to prevent cross-site intrusion when multiple websites are deployed on the vps?

A website is configured with A permission, so that even if website A is intruded, it cannot intrude into website B across sites. If you do not know much about it, we recommend that you install a host management system, such as a free N-point host management system. In this way, the activated space automatically assigns you a permission.

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.