PHP downloads the images in the CSS file. As a senior and professional suede engineer, I have accumulated rich experience in the Internet since I started my junior year. I believe that every web programmer will also have a senior and professional hacker who has accumulated rich experience in the Internet since I started my junior year. I believe that every web programmer will have similar experiences.
You must download the images in the style file. If you encounter a large style file that may contain hundreds of images to be downloaded, the following small code is the most suitable.
<? Php
/*
More & Original PHP Framwork
Copyright (c) 2007-2008 IsMole Inc.
Www.bkjia.com
Author: kimi
Documentation
*/
// Note: Set the PHP timeout.
Set_time_limit (0 );
// Note: get the style file content
$ StyleFileContent = file_get_contents ('images/style.css ');
// The note matches the URL to be downloaded.
Preg_match_all ("/url \ (. *) \)/", $ styleFileContent, $ imagesURLArray );
// Download the addresses to be downloaded in the note loop one by one
$ ImagesURLArray = array_unique ($ imagesURLArray [1]);
Foreach ($ imagesURLArray as $ imagesURL ){
File_put_contents (basename ($ imagesURL), file_get_contents ($ imagesURL ));
}
Bytes. I believe that every web programmer will also have...