欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  后端开发

php遍历目录,生成目录下每个文件的md5值并写入到结果文件中_PHP教程

程序员文章站 2024-02-05 14:29:10
...
 array("';
		$content .= $fileSize;
		$content .= '","';
		$content .= $fileMd5;
		$content .= '"),';
		$content .= "\n";
		
		if (! fwrite ( $fileHandle, $content )) {
			print ($filePath . " can not be written!") ;
		}
	}
	
	/**
	 * 在manifes文件中写入头信息
	 *
	 * @param unknown $fileHandle        	
	 */
	public static function writeMaifestHeader($fileHandle) {
		$header = "


www.bkjia.comtruehttp://www.bkjia.com/PHPjc/755767.htmlTechArticlearray("';$content .= $fileSize;$content .= '","';$content .= $fileMd5;$content .= '"),';$content .= "\n";if (! fwrite ( $fileHandle, $content )) {print ($filePath . " can not be wr...