Fail to discuss _ PHP Tutorial

Source: Internet
Author: User
You did not discuss it. It is a terrible task to do less website information. Web pages captured by other websites such as webzip cannot be used without being processed. The article we want is in it. it is very difficult to think about the problem of having less website information. Web pages captured by other websites such as webzip cannot be used without being processed. The article we want is here. how can we find a solution? Because I am relatively lazy, I have never thought about manual processing. But the net still has to do it, and there is no way to compile a php program. maybe this task can be completed. :)
The following is the source code for your reference:
// Php multi-layer automatic file conversion system.
// Applies to continuous files.
// Parameter description
// $ Site directory to be processed
$ Site = "d:/update ";
Insert ($ site );
Function cchange ($ path1, $ path2 ){
$ Lastchar = "";
$ Temp = file ($ path1 );
For ($ I = 0; $ I $ Temp [$ I] = str_replace ("
"," # Br # ", $ temp [$ I]);
$ Temp [$ I] = str_replace ("
"," # Br # ", $ temp [$ I]);
$ Lastchar. = $ temp [$ I];
}
$ Lastchar = strip_tags ($ lastchar );
$ Handle = fopen ($ path2, "w ");
Fwrite ($ handle, $ lastchar );
Fclose ($ handle );
$ Ctemp = file ($ path2 );
$ Max = 0;
$ Pos = 0;
$ End = "";
For ($ I = 0; $ I // Capture core processing fields in the article
// To be improved
$ Ctemp [$ I] = str_replace ("# br #","
", $ Ctemp [$ I]);
$ Ctemp [$ I] = ltrim ($ ctemp [$ I]);
$ Ctemp [$ I] = ereg_replace ("[f] {0,}", "", $ ctemp [$ I]);

While (substr (trim ($ ctemp [$ I]), 0, 4) ="
"){
$ Ctemp [$ I] = trim (substr (trim ($ ctemp [$ I]), 4 ));
}
If (strlen ($ ctemp [$ I])> 20)
$ End. = $ ctemp [$ I];
}
$ Handle = fopen ($ path2, "w ");
Fwrite ($ handle, $ end );
Fclose ($ handle );
}

Function insert ($ path ){
$ D = dir ($ path );
While ($ entry = $ d-> read ()){
If ($ entry! = "." & $ Entry! = ".."){
If (is_dir ($ path. "/". $ entry )){
Insert ($ path. "/". $ entry );
Echo $ path ."
";
}
If (! Is_dir ($ path. "/". $ entry )){
Cchange ($ path. "/". $ entry, $ path. "/". $ entry );
}
}
}
}

?>
Note: This program is not omnipotent, and some annoying websites cannot help it. However, after statistics, the accuracy can reach 90%. If any hero is interested, you can help me change it or discuss with me how to make it perfect. My contact: oicq: 7750988, email: cairway@263.net.

Bytes. Web pages captured by other websites such as webzip cannot be used without being processed. Here is the article we want...

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.